#include<stdio.h>
#include<conio.h>
#include<process.h>
void main()
{
FILE *f;
char c;
clrscr();
f=fopen("balaram.txt","r+");
if(f==NULL)
{
printf("File can not appending");
exit(1);
}
printf("\n contents read");
while(!feof(f))
{
printf("%c",getc(f));
}
printf("write data and to stop press'.':");
while(c!='.')
{
c=getche();
fputc(c,f);
}
}