#include<stdio.h> // 求e=1/1!+1/2!+1/3!+....+1/n! main() { double e=1,a,s=1; int i; for(i=1;i<=20;i++) { s*=i; a=1/s; e+=a; } printf("%f",e); }
标签:求求,int,double,C语言,include,+....+ From: https://www.cnblogs.com/xkdn/p/17242345.html
#include<stdio.h> // 求e=1/1!+1/2!+1/3!+....+1/n! main() { double e=1,a,s=1; int i; for(i=1;i<=20;i++) { s*=i; a=1/s; e+=a; } printf("%f",e); }
标签:求求,int,double,C语言,include,+....+ From: https://www.cnblogs.com/xkdn/p/17242345.html