#include
#include
void main()
{
FILE *fp;
char ch,filename[10];
scanf("%s",filename);
if((fp=fopen("D:\\filename.txt","w+"))==NULL)
{
printf("Canot open file!\n");
exit(0);
}
ch=getchar();
ch=getchar();
while(ch!='#')
{
fputc(ch,fp);
putchar(ch);
ch=getchar();
}
putchar(10);
fclose(fp);
}
阅读(638) | 评论(0) | 转发(0) |