In the following code (just for experiment purpose) the fgetchar() take the value present in the system buffer and thus getting terminated , Why?
#include<stdio.h>
#include<conio.h>
int main()
{
printf("Here getch will take the value and it will not echo and will take without enter\n");
getch();
printf("Here getchar will take the value but it will echo on entering ");
getchar();
printf("Here getche will take the value but it will echo not on entering\n");
getche();/*fflush(stdin);*/
printf("now we are going to illustrate the usage of macros");
fgetchar();
}
I have read that fgetchar() works similar to getchar() the only difference being the latter is a macro, is it the only difference???