question

This is a discussion on question within the C++ Programming forums, part of the General Programming Boards category; Originally Posted by Aparavoid Thanks. It's good to know your human(joking). you met my human?...

  1. #16
    Banned ಠ_ಠ's Avatar
    Join Date
    Mar 2009
    Posts
    687
    Quote Originally Posted by Aparavoid View Post
    Thanks. It's good to know your human(joking).
    you met my human?
    ╔╗╔══╦╗
    ║║║╔╗║║
    ║╚╣╚╝║╚╗
    ╚═╩══╩═╝

  2. #17
    The Registered User Aparavoid's Avatar
    Join Date
    May 2009
    Posts
    74
    Yes and he was the most polite and curteous man I have ever met. Your human(whatever that means) is a contribution to society.
    Last edited by Aparavoid; 05-13-2009 at 03:40 PM. Reason: iPhone spell checker failed me

  3. #18
    and the hat of sweating
    Join Date
    Aug 2007
    Location
    Toronto, ON
    Posts
    3,545
    Quote Originally Posted by anon View Post
    Code:
    #include <iostream>
    #include <cstdlib>
    
    int main()
    {
        std::cout << "Hello world\n";
        std::system("pause");
    }
    Is it guaranteed in this program that "Hello world" is printed (before the console closes)?
    Not unless you add std::endl or std::flush to the end of your cout statement.
    "I am probably the laziest programmer on the planet, a fact with which anyone who has ever seen my code will agree." - esbo, 11/15/2008

    "the internet is a scary place to be thats why i dont use it much." - billet, 03/17/2010

  4. #19
    Banned ಠ_ಠ's Avatar
    Join Date
    Mar 2009
    Posts
    687
    hmmm... couldn't have been my human
    ╔╗╔══╦╗
    ║║║╔╗║║
    ║╚╣╚╝║╚╗
    ╚═╩══╩═╝

  5. #20
    The Registered User Aparavoid's Avatar
    Join Date
    May 2009
    Posts
    74
    Your a good little boy and you know it.

  6. #21
    Banned ಠ_ಠ's Avatar
    Join Date
    Mar 2009
    Posts
    687
    I'm fairly certain I'm not a boy
    ╔╗╔══╦╗
    ║║║╔╗║║
    ║╚╣╚╝║╚╗
    ╚═╩══╩═╝

  7. #22
    VA National Guard The Brain's Avatar
    Join Date
    May 2004
    Location
    Manassas, VA USA
    Posts
    903
    It would be nice to have a subforum to put these threads in so we can still have fun
    = a multi-threaded thread
    • "Problem Solving C++, The Object of Programming" -Walter Savitch
    • "Data Structures and Other Objects using C++" -Walter Savitch
    • "Assembly Language for Intel-Based Computers" -Kip Irvine
    • "Programming Windows, 5th edition" -Charles Petzold
    • "Visual C++ MFC Programming by Example" -John E. Swanke
    • "Network Programming Windows" -Jones/Ohlund
    • "Sams Teach Yourself Game Programming in 24 Hours" -Michael Morrison
    • "Mathmatics for 3D Game Programming & Computer Graphics" -Eric Lengyel

  8. #23
    Registered User
    Join Date
    May 2009
    Posts
    23
    if system pause is possible in cin and cout then what law of physics would it defy

  9. #24
    Banned ಠ_ಠ's Avatar
    Join Date
    Mar 2009
    Posts
    687
    Quote Originally Posted by luke luvevou View Post
    if system pause is possible in cin and cout then what law of physics would it defy
    all of them
    ╔╗╔══╦╗
    ║║║╔╗║║
    ║╚╣╚╝║╚╗
    ╚═╩══╩═╝

  10. #25
    Registered User
    Join Date
    Oct 2006
    Posts
    2,510
    Quote Originally Posted by ಠ_ಠ View Post
    all of them
    your avatar looks like Pintsize from QC

  11. #26
    Registered User BuzzBuzz's Avatar
    Join Date
    Feb 2009
    Posts
    89
    Quote Originally Posted by luke luvevou View Post
    if system pause is possible in cin and cout then what law of physics would it defy
    Like the use of system("PAUSE") with cin, instead of posting the question you should be setting up tests to examine the use and interaction of system("PAUSE") with the laws of physics.

    If you find that you get any errors then you should post the error and your code and then someone will attempt to help you. The help is usually proportionate to amount of effort you put in.

    However, if you do destroy the multiverse with your hamfisted keyboard mashing I, for one, will be most upset.
    Any help I give may be classified as:
    The Blind leading the Blind...
    Currently working through:
    "C++ Primer Plus"

  12. #27
    VA National Guard The Brain's Avatar
    Join Date
    May 2004
    Location
    Manassas, VA USA
    Posts
    903
    In order for the System( ) function to be used as a cin / cout parameter, the function would have to return ostream reference I believe.
    • "Problem Solving C++, The Object of Programming" -Walter Savitch
    • "Data Structures and Other Objects using C++" -Walter Savitch
    • "Assembly Language for Intel-Based Computers" -Kip Irvine
    • "Programming Windows, 5th edition" -Charles Petzold
    • "Visual C++ MFC Programming by Example" -John E. Swanke
    • "Network Programming Windows" -Jones/Ohlund
    • "Sams Teach Yourself Game Programming in 24 Hours" -Michael Morrison
    • "Mathmatics for 3D Game Programming & Computer Graphics" -Eric Lengyel

  13. #28
    and the hat of sweating
    Join Date
    Aug 2007
    Location
    Toronto, ON
    Posts
    3,545
    Quote Originally Posted by The Brain View Post
    In order for the System( ) function to be used as a cin / cout parameter, the function would have to return ostream reference I believe.
    That's if you do this:
    Code:
    cout << system( "PAUSE" );
    which I don't think is the case here. Also, system() returns an int, so the above code would print out the return value of system().
    "I am probably the laziest programmer on the planet, a fact with which anyone who has ever seen my code will agree." - esbo, 11/15/2008

    "the internet is a scary place to be thats why i dont use it much." - billet, 03/17/2010

Page 2 of 2 FirstFirst 12
Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Alice....
    By Lurker in forum A Brief History of Cprogramming.com
    Replies: 16
    Last Post: 06-20-2005, 02:51 PM
  2. Debugging question
    By o_0 in forum C Programming
    Replies: 9
    Last Post: 10-10-2004, 05:51 PM
  3. Question about pointers #2
    By maxhavoc in forum C++ Programming
    Replies: 28
    Last Post: 06-21-2004, 12:52 PM
  4. Question...
    By TechWins in forum A Brief History of Cprogramming.com
    Replies: 16
    Last Post: 07-28-2003, 09:47 PM
  5. Question, question!
    By oskilian in forum A Brief History of Cprogramming.com
    Replies: 5
    Last Post: 12-24-2001, 12:47 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21