[求助]文件高手进来!
题目:用count变量计算luoming.txt文本中的字符个数#include<stdio.h>
#include<stdlib.h>
main()
{FILE *fp;
long count=0;
if((fp=fopen("luoming.txt","r"))==NULL)
{printf("cannot open file!\n");
exit(0);
}
while(!feof(fp))
{ //那位高手帮我看看。这里填入一句话
count++;
}
printf("\ncount=%d\n",count);
fclose(fp);
}
[此贴子已经被作者于2005-5-6 8:34:57编辑过]