Acorn Computers BBC Micro Model B w/8271 — Acorn BBC Micro Model B w/8271 User Guide Manual PDF

78 10 FOR S = 100 TO 90 STEP -1 20 PRINT S,S/2,S/5 30 NEXT >RUN 100 50 20 99 49.5 19.8 98 49 19.6 97 48.5 19.4 96 48 19.2 95 47.5 19 94 47 18.8 93 46.5 18.6 92 46 18.4 91 45.5 18.2 90 45 18 Here is a program which uses several FOR...NEXT loops. Some are ‘nested’ within each other in the way that one REPEAT...UNTIL loop was included within another. 10 FOR ROW = 1 TO 5 20 FOR STAR = 1 TO 10 30 PRINT"*"; 40 NEXT STAR 50 FOR STRIPE = 1 TO 20 60 PRINT "="; 70 NEXT STRIPE 80 PRINT 90 NEXT ROW 100 FOR ROW = 1 TO 6 110 FOR STRIPE = 1 TO 30 120 PRINT"="; 130 NEXT STRIPE 140 PRINT 150 NEXT ROW