C语言编程:ex=1+x/1!+x2/2!+x3/3!+……+xn/n!+…… 要求输入x的值后能计算ex的值,用循环编程.谢谢

来源:学生作业学帮网 编辑:学帮网 时间:2024/06/06 05:13:00

C语言编程:ex=1+x/1!+x2/2!+x3/3!+……+xn/n!+…… 要求输入x的值后能计算ex的值,用循环编程.谢谢

#include
#include
#define N 10
double f(int n)
{ int i,s=1;
for(i=1;i