50PRINT “ARITHMETIC OPERATION YOU WANT”

60PRINT “ME TO DO FOR YOU”

70INPUT R$

100IF R$=“A” THEN C=A+B : GOTO 200

110IF R$=“S” THEN C=A-B : GOTO 200

120IF R$=“M” THEN C=A*B : GOTO 200

130IF R$=“D” THEN C=A/B : GOTO 200

140PRINT “YOU MADE A MISTAKE”

150PRINT “TRY AGAIN”

160GOTO 30

200PRINT “THE ANSWER IS ”;C

300END

This is a long program but it has a lot of new information that is worthwhile to know. Line 70 contains an INPUT statement without the prompt string. Lines 100 through 130 contain two statements for the command when the condition is true. One is a LET statement without the word LET (C=A+B) and the other is a GOTO statement. Both of the statements are separated from each other by the colon ( : symbol). The GOTO statement tells the computer the number of the next statement to do. Line 140 is an error trap. It tells you that you have not followed instructions.

You can experiment some more with this program and put in a decision to start the program all over again.

If you change line 300 to be GOTO 10, the program runs continually. You can stop it by pressing the SHIFT and BREAK keys and resume it by typing in CONT and press

ENTER.

43