习题2-4
![](http://images0.cnblogs.com/blog/570517/201310/30214828-aa723db414e1463fb8b68de6f182b466.png)
#include<stdio.h> int main(void) { int m,n,i; double y; y=0; printf("Entern,m:"); scanf("%d%d",&m,&n); for(i=m;i<=n;i++) y=y+(i*i+1.0/i); printf("y=%Lf\n",y); }
#include<stdio.h> int main(void) { int m,n,i; double y; y=0; printf("Entern,m:"); scanf("%d%d",&m,&n); for(i=m;i<=n;i++) y=y+(i*i+1.0/i); printf("y=%Lf\n",y); }