This list contains the defined keys.
There is a one-to-one correspondence
between the defined keys and the pos-
Match the key string to the list of de-
returns 1 if
the key string is "A", 2 if the key
string is "B", 3 if the key string is
if no match occurs.
Make a copy of the position to use as
a flag. If the position is 1, 2, or 3, exe-
cute the THEN clause. If the position
is 0, execute the ELSE clause.
The key was defined, so put a true
flag on the stack.
The key was undefined, so display an
error message and beep.
Display an error message.
Sound a tone.
Wait 1 second.
End the IF ... THEN ... ELSE ...
END structure. If the key was defined,
the position and a true flag are on the
stack. If the key was undefined, only
the position (which is also a false flag)
is on the stack.
End the outer indefinite loop. If the
key was defined, the loop ends with
the position on the stack. If the key
was undefined, the loop clause is
Given the list of possible outcomes
and a position, get the correponding
27: Interactive Programs