帮我看下,主函数出错在哪?
#include <stdio.h>int wr4 (FILE *fptr)
{
char ch;
int c=0;
fseek (fptr,0,SEEK_SET);
while (1){
ch=fgetc(fptr);
if(ch!=EOF)c++;
else break;
}
return c;
}
void main ()
{
FILE *p=fopen("f:\\xxk\\lianxi.txt","w");
wr4 (p);
fclose (p);
}
帮我看下,主函数出错在哪?