Thread: input buffer

  1. #1
    Registered User
    Join Date
    Oct 2001
    Posts
    28

    input buffer

    Does any one know of a reliable way to flush the input buffer from the keyboard apart from fflush(which dosen't work all the time) Thanks for any suggestions you may have

  2. #2
    Banned Troll_King's Avatar
    Join Date
    Oct 2001
    Posts
    1,784
    while(getchar() != '\n') continue;

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. can someone help me with these errors please code included
    By geekrockergal in forum C Programming
    Replies: 7
    Last Post: 02-10-2009, 02:20 PM
  2. Can't seem to come to conclusion : cin.ignore()
    By SkyHi in forum C++ Programming
    Replies: 8
    Last Post: 05-13-2005, 08:57 PM
  3. How can you tell if the input buffer is empty?
    By Punkture in forum C Programming
    Replies: 1
    Last Post: 06-04-2003, 05:10 PM
  4. text input buffer clearing
    By red_Marvin in forum C++ Programming
    Replies: 4
    Last Post: 03-20-2003, 03:17 PM
  5. Flushing the input buffer.
    By civix in forum C++ Programming
    Replies: 6
    Last Post: 08-19-2002, 06:41 PM