CPP practice question 6 of 30

What will happen when you attempt to compile and run the code below, assuming that you enter the following sequence: one two three? #include #include…

Choose your answer, then check it against the explanation.

What will happen when you attempt to compile and run the code below, assuming that you enter the following sequence: one two three? #include #include using namespace std; int main () { string a; cin.getline(a); cout<<a<<endl; return 0; } Program will output:
Answer options
Question 6 of 30

Keep practicing

Take the free CPP practice test

Ten exam-style questions with answers and explanations, plus the exam facts and study guides.

Start the free practice test

More questions

Other CPP practice questions

Scroll to Top