osx - C++ only prints one statement -
i've started learning c++ programming language, using xamarin studio ide on osx 10.9.5 , following c++ language tutorial juan soulie'.
i'm following guide says whenever compile code:
#include <iostream> using namespace std; int main() { cout << "hello world! "; cout << "i'm c++ program"; return 0; }
the terminal screen appears , displays this!
hello world! press key continue... logout [process completed]
is i'm doing wrong or issue compiler? tried xcode got same results.
sorry if question sounds dumb!
marc
i can't reproduce on machine i'm guessing need flush buffer, either cout << endl;
or cout.flush();
Comments
Post a Comment