qfedu-c-level/day14/d6.c

13 lines
280 B
C

#include <stdio.h>
#include <string.h>
int main()
{
FILE *f = fopen("d6.txt", "a");
// char content[20] = "hello disen";
char *m = "小李";
int n = fputs(m, f); // 单字符写入
printf("已追加内容的结构 n = %d\n", n);
fclose(f);
return 0;
}