Sunday, July 12, 2009

Visual Studio 2005 C++ Help?

I'm new to C++, please help.





Here is my code. When I run it, the window disappears right away. How can the "Press any key to exit" appears?





#include %26lt;iostream%26gt;





using namespace std;





int main()


{


cout %26lt;%26lt; "Hello world.";





return 0;


}

Visual Studio 2005 C++ Help?
obviously it will because you do not have any pause, use getch() after cout%26lt;%26lt;"hello world";





Getch will wait until user presses any key then exits.

customer survey

No comments:

Post a Comment