fflush() is only used for flushing OUTPUT buffer. But how do I flush 
input buffer?

One way is using:-

while ((ch = getchar()) != '\n' && ch != EOF);

IS there any OTHER WAY?

I also tried using library function:- setbuf(stdin,NULL);
but no success..

Why?

-- 
Abhijeet Rastogi
(shadyabhi)
http://www.google.com/profiles/abhijeet.1989



[Non-text portions of this message have been removed]

Reply via email to