GLBasic Programming/BASIC/GOTO

From Wikibooks, open books for an open world
Jump to navigation Jump to search

This is the use of GOTO:

// A GOTO sample 
beginning:
LET a=RND(600)
LET b=RND(400)
PRINT "Wow",a ,b
SHOWSCREEN
MOUSEWAIT
GOTO beginning

Eplanation[edit | edit source]

It repeats the part "beginning", so the numbers change fast.

Previous: BASIC/DO...LOOP Index Next: BASIC/Random Number Generation