5 RANDOMIZE TIMER
10 CLS:PRINT"NOT-ONE"
20 PRINT:PRINT TAB(7) "COPYRIGHT 1979 CREATIVE COMPUTING MORRISTOWN, NJ"
40 DIM T(50),R(21),C(21),L(21)
42 CLS:PRINT"INSTRUCTIONS":PRINT:PRINT
43 PRINT"YOU MAY PLAY ANY NUMBER OF ROUNDS UP TO 21"
45 INPUT"HOW MANY ROUNDS DO YOU WISH TO PLAY";NN
50 IF NN >21 OR NN<0 OR INT(NN)<>NN THEN 45
60 REM
260 CLS:FOR T=1 TO NN:PRINT "ROUND";T;:PRINT "--------";CHR$(31)
270 X=X+1:R1=INT(6*RND(1))+1
280 R2=INT(6*RND(1))+1
300 PRINT R1+R2;
310 IF X>1 THEN 330
320 T(1)=R1+R2:GOTO 370
330 T(X)=R1+R2
340 IF T(1)<>T(X) THEN 370
350 PRINT"YOU GET A ZERO FOR THIS ROUND"
360 X=0:T1=0:GOTO 410
370 T1=T1+T(X)
380 INPUT"ROLL AGAIN";B$
390 IF LEFT$(B$,1)="Y" THEN 270
391 IF LEFT$(B$,1)>"N" THEN PRINT "PARDON?":GOTO 380
400 R(T)=T1:X=0:T1=0:FOR A=1 TO 50:T(A)=0:NEXT:GOTO 410
410 PRINT CHR$(31);
420 RESTORE
430 R1=INT(6*RND(1))+1:R2=INT(6*RND(1))+1
440 FOR D = 2 TO R1+R2:READ L(D):NEXT:D=R1+R2
450 FOR C = 1 TO L(D):IF C= 1 THEN 480
460 R1=INT(6*RND(1))+1:R2=INT(6*RND(1))+1
480 PRINT"COMPUTER'S ROLL #";C;CHR$(8);":";R1+R2
490 IF C>1 THEN 510
500 T(1)=R1+R2:GOTO 550
510 T(C)=R1+R2
520 IF T(1)<>T(C) THEN 550
530 PRINT"THE COMPUTER GETS A ZERO FOR ITS TURN!!"
540 T1=0:GOTO 560
550 T1=T1+T(C):NEXT C
560 C(T)=T1:T1=0:X=0
570 C2=C2+C(T):C1=C1+R(T)
580 PRINT:FOR B=1 TO 50:T(B)=0:NEXT
590 REM
600 IF C2<C1 THEN 620
610 PRINT "COMPUTER:";C2;"YOU:";C1;CHR$(30);:GOTO 630
620 PRINT "YOU:";C1;"COMPUTER:";C2;CHR$(30);
630 NEXT T
640 DATA 18,18,9,9,6,6,6,9,9,18,18
650 CLS
660 PRINT "ROUND";TAB(15);"YOU";TAB(25);"COMPUTER"
670 PRINT "-----";TAB(15);"---";TAB(25);"--------"
680 FOR E=1 TO NN:PRINT E;R(E);C(E)
690 NEXT E:
695 ?"TOTAL";C1;C2
700 INPUT "WANT TO PLAY AGAIN?";N$
710 IF LEFT$(N$,1)="Y" THEN RUN
720 IF LEFT$(N$,1)="N" THEN END
730 PRINT "INVALID RESPONSE.":GOTO 700