c_______________________________________________________________________________

c     Calculo del numero e (suma de n terminos de la serie).          Version DO

      implicit real*8 (a-h,o-z)

      parameter(UNO=1.d+00)

    1 write(6,'(/,a,$)') ' Numero de terminos = '
      read(5,*) n
      if (n.lt.0) goto 1

      e=UNO
      do i=n,1,-1
        e=UNO+e/dble(i)
      enddo

      write(6,100) n,e
  100 format(/,' n = ',i10,'      -> e = ',e24.16)

      read(5,'()')
      call exit(0)

      end
