Hello everyone,
While learning C File I/O I tried the following code :
#gcc prg.cCode:#include<stdio.h>
int main()
{
FILE *fp;
fp=fopen("source.txt","rb");
printf("fp = %p\n",fp++);
printf("fp = %p\n",fp);
return 0;
}
#./a.out
Gives the following output :
fp = 0x8e2a008
fp = 0x8e2a09c
On incrementing fp and printing the values there is a difference of 0X94 or 148. How does the difference come to 148?
Thank you.