wait, wait countdown

Prev Next

Function Names

wait, wait countdown

Description

The program will sleep for a specified number of seconds or until user interaction (any key pressed), whatever happens first. The granularity is 0.001, i.e. milliseconds. The ... countdown suffix will output the remaining time to sleep once per second.

Call as: procedure or function

Restrictions

Indirect parameter passing is disabled

Parameter count

1

Parameters

No.TypeDescription
1
input
numeral Time

Time in seconds. Granularity is in ms, e.g. sleep(0.03) sleeps for 30 milliseconds.

2
input
string Prompt

Prompts a message that sleeping is in progress

Return value

TypeDescription
string Time in seconds

Entered character, or blank string if no key has been pressed to stop waiting.

Examples

               sleep countdown (3);

Output

Software will display a down-counting number on the same row

See also

sleep
sleep countdown
wait until
wait until countdown
input quick