cin just stopped working.

My program keeps skipping cin and moving on to the next step.

1
2
3
4
5
6
7
8
9
  #include <iostream>
using namespace 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).

Please help.
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?
Just learned Sublime Text doesn't support console interaction...

from my text editor "Sublime Text 2"

never heard it before.

but, well, i see you solved your own question.
good, then.
I've checked it works fine..
Topic archived. No new replies allowed.