标题:1
只看楼主
Rank: 1
等 级:新手上路
帖 子:255
专家分:0
注 册:2005-4-25
 问题点数:0 回复次数:2 
1
1

[此贴子已经被作者于2005-5-31 21:21:52编辑过]


2005-05-31 20:10
Rank: 1
等 级:新手上路
帖 子:255
专家分:0
注 册:2005-4-25
得分:0 
1

[此贴子已经被作者于2005-5-31 21:22:17编辑过]



/bbs/showimg.asp?BoardID=5&filename=2005-4/2005427111228529.jpg" border="0" onload="if(this.width>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.alt='Click here to open new window\nCTRL+Mouse wheel to zoom in/out';}" onmouseover="if(this.width>screen.width*0.7) {this.resized=true; this.width=screen.width*0.7; this.style.cursor='hand'; this.alt='Click here to open new window\nCTRL+Mouse wheel to zoom in/out';}" onclick="if(!this.resized) {return true;} else {window.open('http://bbs./bbs/showimg.asp?BoardID=5&filename=2005-4/2005427111228529.jpg');}" onmousewheel="return imgzoom(this);" alt="" /> 欢迎加入C语言QQ群698156 我们都是菜鸟乃至新手 坚信有一天定能展翅高飞 因为有着努力的决心 衷心盼望你的到来 让我们一起进步
2005-05-31 20:12
城门口
Rank: 1
等 级:新手上路
帖 子:15
专家分:0
注 册:2005-4-8
得分:0 

有几个地方的fpa,fpb 搞混了,putchar(fgetc(fb))你还有个括号没括!程序如: #include "stdio.h" main() { FILE *fpa,*fpb; if((fpa=fopen("a.txt","r"))==NULL) {printf("error1a");exit(0);} if((fpb=fopen("b.txt","w"))==NULL) {printf("error1b");exit(0);}

while(!feof(fpa)) fputc(fgetc(fpa),fpb);

if(fclose(fpa)||fclose(fpb)){printf("error2a'or'b");exit(0);}

if((fpb=fopen("b.txt","r"))==NULL) {printf("error1b");exit(0);}

while(!feof(fpb)) putchar(fgetc(fpb)); if(fclose(fpa)){printf("error2b");exit(0);}

}



2005-05-31 21:24



参与讨论请移步原网站贴子:https://bbs.bccn.net/thread-19797-1-1.html




关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 1.630928 second(s), 7 queries.
Copyright©2004-2025, BCCN.NET, All Rights Reserved