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 using namespace std; int main () { string a; cin.getline(a); cout

Full set: 228 questions
Answer options
A: one
B: one two three
C: runtime exception
D: compilation error Correct answer
E: the result is unspecified
Correct Answer:
D. compilation error
Scroll to Top