Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int main(int argc, const char * argv[])
- {
- for(int i = 0;;++i)
- {
- cout << i << endl;
- if (_kbhit())
- {
- int c = _getch();
- if (c == 0x1B) break;
- }
- }
- }
- for(int i = 0;;++i)
- {
- cout << i << endl;
- if(_kbhit())
- {
- while(_kbhit()) _getch();
- }
- else
- {
- _getch();
- }
- }
- while(_kbhit()) _getch();
Add Comment
Please, Sign In to add comment