My program keeps skipping cin and moving on to the next step.
1 2 3 4 5 6 7 8 9
#include <iostream>
usingnamespace std;
int main() {
int numberOne;
cin >> numberOne;
cout << numberOne;
return 0;
}
In this very simple program, it does't wait for user input and just prints out some gibberish number (since numberOne was not initialized with a value).
Ok, so I played with it some more. When I compile it manually, it works fine, but when I compile it with the built in features from my text editor "Sublime Text 2" it just skips cin. Does anyone know why this is the case?