wait, waitc#
Purpose#
Waits until any key is pressed.
Format#
wait;
waitc;
Remarks#
If you are working in terminal mode, these commands do not “see” any keystrokes until ENTER is pressed. Format clears any pending keystrokes before waiting until another key is pressed.
Examples#
// Pause until a key is pressed
print "Press any key to continue...";
wait;
// Clear pending keystrokes, then wait for a new one
print "Press a key to start...";
waitc;
Source#
wait.src, waitc.src