#include <iostream>
#include <fstream>
#include <cmath>
using namespace std;
int main(){
double e=0.,t=1.,epsilon=1.e-6;
int i=1;
while(t>=epsilon){
  e=e+t;
  t=t/i;
  i++;
  }
cout<<"Convergencia con i="<<i<<" terminos"<<endl;
cout<<"Termino final= "<<t<<endl;
cout<<"e="<<e<<endl;
return 0;
}
