学习C语言文件读写的基本流程
最编程
2024-08-13 10:21:22
...
#include <stdio.h>
int main()
{
FILE *fp = NULL;
fp = fopen("./test.txt", "w+");
fprintf(fp, "This is testing...\n");
fputs("This is testing...\n", fp);
fclose(fp);
return 0;
}
上一篇: 深入剖析C语言文件操作
下一篇: C语言文件读写(1)-文本文件读取操作