File tree Expand file tree Collapse file tree 1 file changed +18
-3
lines changed Expand file tree Collapse file tree 1 file changed +18
-3
lines changed Original file line number Diff line number Diff line change 101020 DEFINT X,Y
111125 PRINT "printing var list"
121230 VARLIST
13- 34 REM
14- 35 REM simple loop
15- 36 REM
13+ 44 REM
14+ 45 REM simple loop
15+ 46 REM
161650 FOR I= 1 TO 3
171760 PRINT "loop with NEXT I" I
181870 NEXT I
88881740 PRINT A$, "len=" len (A$)
89891750 PRINT "(1:5), should produce HELLO: " A$(1 :5 )
90901760 PRINT "(4:5), should produce LO: " A$(4 :5 )
91+ 1770 REM
92+ 1771 REM assign string into a slice
93+ 1772 REM
94+ 1780 A$= "HELLO WORLD"
95+ 1790 A$(1 :4 )= "GOOD"
96+ 1791 PRINT "assigned into a slice, should produce GOODO WORLD: " A$
91971800 REM
92981801 REM concats
93991802 REM
1171231910 PRINT "using SPACE$, should print three spaces and HELLO: " ;SPACE$ (3 );"HELLO"
1181241920 PRINT "using STRING$, should print HELLO three times: " ;STRING$ ("HELLO" ,3 )
1191251930 PRINT "using STRING$ with ASCII value, should print three X's: " ;STRING$ (88 ,3 )
126+ 2000 REM
127+ 2001 REM bin/oct/hex conversions
128+ 2002 REM
129+ 2010 PRINT "Convert hex FFFE to number, should print 65534: " ;HEX("FFFE" )
130+ 2020 PRINT "Convert oct 7654 to number, should print 4012: " ;OCT("7654" )
131+ 2030 PRINT "Convert bin 101010 to number, should print 42: " ;BIN("101010" )
132+ 2040 PRINT "Convert 5432 to hex, should print 1538: " ;HEX$ (5432 )
133+ 2050 PRINT "Convert 4321 to oct, should print 10341: " ;OCT$ (4321 )
134+ 2060 PRINT "Convert 55 to bin, should print 110111: " ;BIN$ (55 )
1201352294 REM
1211362295 REM make sure B and B() are different
1221372296 REM
You can’t perform that action at this time.
0 commit comments