C programming

Sunday, January 18, 2009

#include #include void main() { clrscr(); FILE *fp; char *fname,c; printf("Enter the file address:"); gets(fname); fp=fopen(fname,"w"); printf("Enter some thing:"); while((c=getchar())!=EOF) putc(c,fp); fclose(fp); fp=fopen(fname,"r"); printf("The file contain:"); while((c=getc(fp))!=EOF) putchar(c); fclose(fp); getch(); }

0 comments:

Visitors

PlugIn.ws - Free Hit Counter, Web Site Statistics, Traffic Analysis

  © Blogger template Leaving by Ourblogtemplates.com 2008

Back to TOP