ok heres the source code for the greater.c program i took getchar() out and put fflush(stdin); and it didnt work than i put fpurge(stdin); and this is what im getting. in the first place with getchar() it was seeing the enter key as a choice. so i did ctrl d and it worked fine than replaced getchar with the other 2 that i said and fflush doesnt do anything the fpurge gives me that error at bottom.
printf("Which character is greater?\n");
printf("Type a single character:");
printf("Type another character:");
printf("'%c' is greater than '%c'!\n",a,b);
else if (b>a)
printf("'%c' is greater than '%c'!\n",b,a);
printf("Next time, dont type the same character twice.");
[boxerboy@localhost ~]$ gcc greater.c -o greater
/tmp/cceNCLIV.o(.text+0x4e): In function `main':
greater.c: undefined reference to `fpurge'
collect2: ld returned 1 exit status
is there something im not seeing?