08/12/17 06:53:50
>>114 UNIX環境だとどちらも違いでないな
#include <stdio.h>
#include <string.h>
int main()
{
char *s = "we will complete your home work!\n";
FILE *fb = fopen("data.bin", "wb"), *ft = fopen("data.txt", "w");
fwrite(s, sizeof(char), strlen(s), fb);
fprintf(ft, "%s", s);
return 0;
}