File IO Practice
File IO Practice
File IO Practice
h>
#include <conio.h>
void main()
{
FILE *fp;
fp=fopen("myfile.txt","r+");
if(fp!=0)
{
fprintf(fp,"%06d", 123);
fprintf(fp, "%06.2f", 55.0);
fprintf(fp, "%c", 'r');
fprintf(fp, "%s", "abcdefg");
putc('a', fp);
fputs("abcdef", fp);
fclose(fp);
if(!_getch())
_getch();
}
}