[程序填空题]以下程序的功能是将C语言源程序文件exam.c中用反斜杠与星号括起来的非嵌套注释删除,然后存入文件exam.out中。请填入适当内容。 #include
void delcomm(FILE *fp1,FILE *fp2) { int c,i=0; while(( )!=EOF) if(c=='\n') fprintf(fp2,"\n"); else switch(i) { case 0:if(c=='/') i=1; else fprintf(fp2,"%c",c); break; case 1:if(c=='*') i=2; else {fprintf(fp2,"%c",c); i=0;} break; case 2:if(c=='*')i=3; break; case 3:i=(c=='/')? ; break; } } int main() { FILE *fp1,*fp2; fp1=fopen("exam.c","r"); fp2=fopen("exam.out","w"); delcomm( ); fcloseall(); return 0; }