5 OPEN "OUTPUT.TXT" FOR OUTPUT AS 1
10 DEF FNA = 2
15 ON X GOTO 100, 200
20 DEF FNA = 1
40 PRINT#1, FNA
50 X = 2: GOTO 10
90 PRINT 90, FNA
100 PRINT#1, 100, FNA
200 PRINT#1, 200, FNA
900 PRINT#1, "END"
999 CLOSE

