12.07.2015 Views

page-1983-101-timex-sinclair-programming-tricks

page-1983-101-timex-sinclair-programming-tricks

page-1983-101-timex-sinclair-programming-tricks

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

After that, it's back to line 10 for a complete new runthrough.Program Listing10 CLEAR15 LET W=JJ20 LET R=JJ25 DIM 1\.$(6,7)30 DIM P$(7)35 LET S=INT(lO*RND)40 IF S6 THEN GOTO 3060 LET A$(l)="BUTLER"70 LET A$(2)="NANNYn80 LET A$(3)=•MAID"90 LET A$(4)=•soNn100 LET A$(5)=•coACH"110 LET A$(6)=•wIFEn120 PRINT "WHO KILLED THE DUKE?n130 PRINT •wAS I~ THE ••• •140 FOR L=l TO 6145 PRINT A$(L)150 NEXT L160 INPUT P$165 CLS170 IF A$(S}=P$ THEN GOTO 200180 PRINT "NOT ";P$190 LET W=W+l195 GOTO 120200 LET R=R+l210 PRINT P$;" DID ITn220 PRINT •youR SCORE IS ••• •230 PRINT R;• RIGHT •;w;• WRONGn240 PRINT250 GOTO <strong>101</strong>6 Batting AverageOnce you know the number of times you were rightand wrong in a game, as in Tip Number 15, it's fun to30

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!