GOKEY
Format: GOKEY expr
Supported by: Floating Point BASIC 2.2
Similar commands:
COMX BASIC V1.00: KEY
Pecom 32 BASIC, Pecom 64 BASIC 1.0 and 4.0, Telmac SBASIC v 24.3: KEY
Conditional branch statement if a key is pressed, BASIC will evaluate the value of expr and branch to it. The value of the key will be assigned to a variable named KEY. If no such line number exists, BASIC will give an ERROR. BASIC will continue execution to the following line if no key is pressed.
10 GOKEY 30 20 GOTO 10 30 PR CHR$ (KEY) 40 GOTO 10
This program will wait for a key press and the print the key pressed.