//////// file_operations.c ////////
#include <stdio.h>
int main(void)
{
char temp[100];
FILE *write_to_file = fopen("file.txt","w");
fprintf(write_to_file,"%08x",0xC12E3A4);
fclose(write_to_file);
FILE *read_from_file = fopen("file.txt", "rb");
fscanf(read_from_file,"%s",temp);
printf("String read from file=%sn",temp);
fclose(read_from_file);
return 0;
}
[raja@AGRAJA ~]$ gcc -Wall file_operations.c
[raja@AGRAJA ~]$ ./a.out
String read from file=0c12e3a4
Download here:

