RETURN
You can use the RETURN command to return to the program location of the last jump performed.
RETURN
This command does not return a value.
In order to use the GOSUB command you must create a subroutine in your program that terminates with the RETURN command. To create a subroutine you must write a label in your program followed by a sequence of commands. The label can be made up from any combination of alphabetic characters, but you must end the declaration of the label using a colon(:). You only need to use a colon when you are declaring the label, and should not be used when calling the label from a GOSUB command.
PRINT "start"
GOSUB _subroutine
WAIT KEY
END
_subroutine:
PRINT "inside subroutine"
RETURN
CORE Commands Menu
Index