0
Why do we use getch() in c++
4 Respuestas
+ 2
getch() is used to make the console wait till a key is pressed. If placed at the end of the program, getch() make the output window to hold till a key is pressed.
+ 1
Varun Goyal what you said is actually the half use of it. getch() is primarily used to return the ascii code of the key pressed as it is a function with a return value and not void. So actually for returning this value it has to keep waiting untill any key is pressed.
0
To make the screen of outbuts remain const
0
thanks, to all those who answered my question