#include<stdio.h>
main( )
{FILE*fp;
char ch,filename[10];
scanf("%s",filename);
if((fp=fopen(filename,"w"))==NULL)
{printf("cannot open file\n");
exit(0);}
ch=getchar();
ch=getchar( );
while(ch!='#')
{fputc(ch,fp);putchar(ch);
ch=getchar();
}
fclose(fp);
}
就这么个程序,就出错了7个,郁闷 高手教我啊
1)unable to open include file "stdio.h"
2)undefined symbol 'FILE' in function main
3)....... 'fp'.......
4)code has no effect in function main
5)expression syntax in function main
6)undefined symbol "filename" in function main
7)..... 'NULL'....
我郁闷啊 怎么就没定义呢,明明定义了啊,还有这个NULL难道还需要定义!!!!
高手快帮我啊!!!!