xxxxxxxxxx
#include <stdio.h>
#include <stdlib.h>
int main()
{
FILE *fp;
char ch;
int loc;
fp=fopen("abc.txt","r+");
printf("\nEnter a character: ");
scanf("%c",&ch);
printf("Enter the location of the character: ");
scanf("%d",&loc);
fseek(fp,loc-1,SEEK_SET);
putc(ch,fp);
fclose(fp);
return 0;
}
xxxxxxxxxx
#include <stdio.h>
#include <stdlib.h>
int main()
{
FILE *fp;
char ch;
int loc;
fp=fopen("abc.txt","r+");
printf("\nEnter a character: ");
scanf("%c",&ch);
printf("Enter the location of the character: ");
scanf("%d",&loc);
fseek(fp,loc-1,SEEK_SET);
putc(ch,fp);
fclose(fp);
return 0;
}
xxxxxxxxxx
#include <stdio.h>
#include <stdlib.h>
int main()
{
FILE *fp;
char ch;
int loc;
fp=fopen("abc.txt","r+");
printf("\nEnter a character: ");
scanf("%c",&ch);
printf("Enter the location of the character: ");
scanf("%d",&loc);
fseek(fp,loc-1,SEEK_SET);
putc(ch,fp);
fclose(fp);
return 0;
}
xxxxxxxxxx
#include <stdio.h>
#include <stdlib.h>
int main()
{
FILE *fp;
char ch;
int loc;
fp=fopen("abc.txt","r+");
printf("\nEnter a character: ");
scanf("%c",&ch);
printf("Enter the location of the character: ");
scanf("%d",&loc);
fseek(fp,loc-1,SEEK_SET);
putc(ch,fp);
fclose(fp);
return 0;
}
xxxxxxxxxx
#include <stdio.h>
#include <stdlib.h>
int main()
{
FILE *fp;
char ch;
int loc;
fp=fopen("abc.txt","r+");
printf("\nEnter a character: ");
scanf("%c",&ch);
printf("Enter the location of the character: ");
scanf("%d",&loc);
fseek(fp,loc-1,SEEK_SET);
putc(ch,fp);
fclose(fp);
return 0;
}
xxxxxxxxxx
#include <stdio.h>
#include <stdlib.h>
int main()
{
FILE *fp;
char ch;
int loc;
fp=fopen("abc.txt","r+");
printf("\nEnter a character: ");
scanf("%c",&ch);
printf("Enter the location of the character: ");
scanf("%d",&loc);
fseek(fp,loc-1,SEEK_SET);
putc(ch,fp);
fclose(fp);
return 0;
}
xxxxxxxxxx
#include <stdio.h>
#include <stdlib.h>
int main()
{
FILE *fp;
char ch;
int loc;
fp=fopen("abc.txt","r+");
printf("\nEnter a character: ");
scanf("%c",&ch);
printf("Enter the location of the character: ");
scanf("%d",&loc);
fseek(fp,loc-1,SEEK_SET);
putc(ch,fp);
fclose(fp);
return 0;
}
xxxxxxxxxx
#include <stdio.h>
#include <stdlib.h>
int main()
{
FILE *fp;
char ch;
int loc;
fp=fopen("abc.txt","r+");
printf("\nEnter a character: ");
scanf("%c",&ch);
printf("Enter the location of the character: ");
scanf("%d",&loc);
fseek(fp,loc-1,SEEK_SET);
putc(ch,fp);
fclose(fp);
return 0;
}