In c++ you can clear out the io stream with the cin.ignore(). What do you use with scanf()? my problem is when a user enters in two numbers (space between numbers) when prompted for one. The second number is picked up by the next scanf()....I want to clear it out of the stream! Any ideas?
int main ()
printf("enter number (-1 to exit)\n");
printf("entered = %d \n", num);