📄 13_7.cpp
字号:
#include<stdio.h>
#include<conio.h>
#include<process.h>
void main()
{
FILE *fp;
char st[20];
if((fp=fopen("d:\\ test.txt","w"))==NULL)
{
printf("Cannot open file strike any key exit!");
getch();
exit(1);
}
printf("input a string:\n");
scanf("%s",st);
fputs(st,fp);
fclose(fp);
exit(0);
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -