XCode 4 console won't take user input

前端 未结 3 1398
灰色年华
灰色年华 2021-01-03 06:30

In XCode 4, when I run something like this:

string input;
cout << \"Enter command\" << endl;
getline(cin, input);
cout << \"You entered: \"         


        
3条回答
  •  渐次进展
    2021-01-03 06:55

    In the bottom pane of the debug window[which shows variables and their values], there is a search toolbar and a 3 option box in the upper right hand corner. Click on the middle of the three options which will display the main debug output to the right of the variable pane. The top pane is only for output. The right pane can be used to enter input.

    I hope this helps. Sorry that the note is late.

提交回复
热议问题