#include <stdio.h>
#define N 11
int main()
{
int a[N];
int m,i;
FILE *fp, *fpOut;
fp=fopen("c\\data.txt","r");
fpOut=fopen("c\\result.txt","w");
for (i=0;i<11;i++)
{
fscanf (fp,"%d",&a[N]);
}
m=a[0];
for (i=0;i<11;i++)
{
m=m+a[i];
}
fprintf(fpOut,"%d\n",m);
fclose(fpOut);
fclose(fp);
}
supercoko
慕仔1599835