当前位置:首页 > 高级语言程序设计(一)(00342) > 正文内容

将从键盘输入的字符串写入文本文件out.txt,输入的字符串长度小于80。#include #include void main(){char c[80];____________); /*第一空*/if((p=fopen("out.txt", "w"))==NULL){ printf("Can not open file!\n"); exit(0);}gets(____________); /*第二空*/fputs(c,p);fclose(____________); /*第三空*/}

高老师2年前 (2024-03-26)高级语言程序设计(一)(00342)9

将从键盘输入的字符串写入文本文件out.txt,输入的字符串长度小于80。#include #include void main(){char c[80];____________); /*第一空*/if((p=fopen("out.txt", "w"))==NULL){ printf("Can not open file!\n"); exit(0);}gets(____________); /*第二空*/fputs(c,p);fclose(____________); /*第三空*/}

第一空:FILE *p第二空:c第三空:p

扫描二维码免费使用微信小程序搜题/刷题/查看解析。

版权声明:本文由翰林刷题小程序授权发布,如需转载请注明出处。

本文链接:https://doc.20230611.cn/post/442997.html

分享给朋友: