+ 1
Is there any function except getch() which can pause a program (C++)?
conio.h doesn't seem to work in codeblocks
4 odpowiedzi
+ 2
that's because conio.h is extremely outdated. you can use the methods getchar() or getline() to await input
+ 2
also system("pause"); will pause the program until user presses a key
+ 1
_sleep(time); will pause the program for specified time. Replace "time" with the amount of milliseconds you wish the program to be paused. Also MVS complains about this _sleep function, but it works nontheless
+ 1
Thanks!