Thread: flush?

  1. #1
    Registered User
    Join Date
    Mar 2013
    Posts
    36

    flush?

    sorry really simple one here have not come across this before. What is the meaning of flush in the code below.

    Code:
    cout << "Please insert the sizes of the table? ";
    flush(cout);

  2. #2
    Registered User
    Join Date
    Jun 2005
    Posts
    6,815
    Look at this.
    Right 98% of the time, and don't care about the other 3%.

    If I seem grumpy or unhelpful in reply to you, or tell you you need to demonstrate more effort before you can expect help, it is likely you deserve it. Suck it up, Buttercup, and read this, this, and this before posting again.

  3. #3
    Registered User
    Join Date
    Oct 2006
    Posts
    3,445
    you can also use

    Code:
    cout.flush();
    What can this strange device be?
    When I touch it, it gives forth a sound
    It's got wires that vibrate and give music
    What can this thing be that I found?

  4. #4
    Registered User
    Join Date
    Apr 2006
    Posts
    2,149
    You might also run into it being used like this. Does the same thing.

    Code:
    cout << "Please insert the sizes of the table? " << flush;
    It is too clear and so it is hard to see.
    A dunce once searched for fire with a lighted lantern.
    Had he known what fire was,
    He could have cooked his rice much sooner.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Help with input flush
    By KarrieWojo in forum C Programming
    Replies: 12
    Last Post: 12-29-2007, 02:38 AM
  2. File Flush
    By gvector1 in forum C Programming
    Replies: 4
    Last Post: 09-09-2003, 07:50 AM
  3. Flush or something....
    By Inquirer in forum Linux Programming
    Replies: 0
    Last Post: 04-16-2003, 07:55 PM
  4. Flush !!
    By Bones in forum C++ Programming
    Replies: 2
    Last Post: 10-27-2002, 07:44 PM
  5. flush()?
    By onurak in forum C++ Programming
    Replies: 3
    Last Post: 07-21-2002, 09:35 AM

Tags for this Thread