+ 1
Pause in C++
Is there a command in C++, that allows you to pause the console for some amount of time? How to use it?
6 ответов
+ 5
getch(); for C
0
thanks
0
Include dos.h header file
use delay() function where you want to pause an output
in parenthesis as a parameter there will be time passed in millisecond that for how much time you want to pause the console or execution
eg., delay(5000);
It will pause the output or console screen for 5 seconds then after 5 seconds the next step or statement will be executed.
0
And if you want to wait the console screen to wait for you to enter a character before next instruction.then use getch() function that is in conio.h
so include that also if you are using Borland tc 3.0
0
thank you