#include<stdio.h>
main()
{
int i;
char str[100];
FILE *fp;
fp=fopen("out.txt","w");
printf("\nEnter a sentence=");
gets(str);
fprintf(fp,"%s",str);
fclose(fp);
}
main()
{
int i;
char str[100];
FILE *fp;
fp=fopen("out.txt","w");
printf("\nEnter a sentence=");
gets(str);
fprintf(fp,"%s",str);
fclose(fp);
}
No comments:
Post a Comment