BASIC Programming Language

References

  1. PC-BASIC – free, cross-platform GW-BASIC emulator
    1. Documentation

Bubble Sort

100 DIM X(1000) 
200 RANDOMIZE TIMER
300 N = 100
400 FOR I=1 TO N 
500 X(I) = INT(RND * N) + 1
600 NEXT I
700 FOR K=1 TO N-1 
800 FOR J=1 TO N-K 
900 IF X(J)>X(J+1) THEN GOSUB 2000
1400 NEXT J
1500 NEXT K
1600 FOR I=1 TO N 
1700 PRINT X(I);
1800 NEXT I
1900 END
2000 TEMP=X(J)
2100 X(J)=X(J+1)
2200 X(J+1)=TEMP
2300 RETURN

Lottery Picker

40 REM FILE NAME IS VER.8.6.BAS
80 KEY OFF:CLS : WIDTH 80: SCREEN 0
120 DIM NBR(12)
160 DIM L(30)
200 DIM X(30)
204 KEY (2) ON:
208 ON KEY(2) GOSUB 37085:
240 KEY(1) ON:
280 ON KEY(1) GOSUB 37120:
320 BXTOP$ = CHR$(201) + STRING$(78, 205) + CHR$(187)
360 BXSIDE$ = CHR$(186) + STRING$(78, " ") + CHR$(186)
400 BXBOT$ = CHR$(200) + STRING$(78, 205) + CHR$(188)
440 BOXIT$ = BXTOP$ + BXSIDE$ + BXBOT$
480 RANDOMIZE TIMER
520 DIM W(50)
560 COLOR , 0: CLS : COLOR 15, 4: LOCATE 1, 1: PRINT BOXIT$
600 LOCATE 2, 28: PRINT "T E X A S  <>  L O T T O"
640 COLOR 15, 1: LOCATE 5, 1: PRINT BOXIT$
680 LOCATE 6, 25: PRINT "Picken'em with a PC Made Easy!" 
720 LOCATE 4, 2:COLOR 2, 0:PRINT "Ver.8.6":LOCATE 4, 62: COLOR 2, 0: PRINT "F1=QUIT  F2=HELP": COLOR 13, 0
760 REM LOCATE 11,10:PRINT " " ' IF YOU SEND YOUR NUMBERS TO THE PRINTER YOU WILL FIND THEM HERE
810 REM LOCATE 10,10: PRINT " IF YOU SEND YOUR NUMBERS TO THE PRINTER PICK MICROSOFT XPS DOCUMENT WRITER.";
811 REM LOCATE 13,10: PRINT " DO NOT PUT CHECK MARK IN PRINT TO FILE BOX.";
812 REM LOCATE 14,10: PRINT " YOU WILL BE ABLE TO SAVE THEM IN DOCUMENTS FOLDER. FILE NAME ENDS IN (.XPS)";
800 REM LOCATE 13,27:PRINT" " ' C:\aaaaaa\dos2usb";:LOCATE 13,10:PRINT "  "
840 COLOR 7:LOCATE 22,1,0:PRINT"************************** ";:COLOR 18,0:PRINT"Press any key to continue";:COLOR 7,0:PRINT" **************************";: 
880 IN$=INKEY$:IF IN$="" THEN 880
920 PRINT ""
960 GOSUB 37400
1000 LOCATE 10,19:PRINT "1> PICK THREE " :LOCATE 10,45:PRINT"2> PICK FOUR "
1040 LOCATE 12,19:PRINT "3> MEGA MILLION 70/25" :LOCATE 12,45:PRINT "4> TEXAS LOTTO 54"
1080 LOCATE 14,19:PRINT "5> TEXAS TWO STEP 35/35" :LOCATE 14,45:PRINT "6> CASH FIVE 35"
1120 LOCATE 16,19:PRINT "7> POWER BALL 69/26" :LOCATE 16,45:PRINT "8> ALL or Nothing"
1160 LOCATE 18,19:PRINT ""
1200 LOCATE 19,17:PRINT STRING$(46, 205)
1240 LOCATE 20,17:PRINT "PICK <1> <2> <3> <4> <5> <6> <7> OR <8> ";
1280 GOSUB 37640
1320 A$ = INKEY$: IF A$ = "" THEN 1320
1360 IF A$ = "1" THEN 2200
1400 IF A$ = "2" THEN 4360
1440 IF A$ = "3" THEN 16640
1480 IF A$ = "4" THEN 31920
1520 IF A$ = "5" THEN 24240
1560 IF A$ = "6" THEN 6600
1600 IF A$ = "7" THEN 8960
1640 IF A$ = "8" THEN 34400
1680 REM IF A$ = "9" THEN 34400
1720 REM IF A$ = "a" OR A$ = "A" THEN 34286
1760 BEEP:GOTO 1320
1800 REM ' ******************* FORM FEED ROUTEEN *******************************
1840 REM GOSUB 37400
1880 REM COLOR 15, 4: LOCATE 10,14:PRINT "                                                     " :COLOR 15, 4: LOCATE 12,14:PRINT "                                                     "
1920 REM COLOR 15, 4: LOCATE 11,14:PRINT "  Are you sure you want a FORM FEED (Y)es -or- (N)o  ";
1960 REM GOSUB 37640
2000 REM AK$ = INKEY$: IF AK$ = "" THEN 2000
2040 REM IF AK$ = "Y" OR AK$ = "y" THEN LPRINT CHR$(12); : GOTO 920
2080 REM IF AK$ = "N" OR AK$ = "n" THEN 920
2120 REM BEEP: GOTO 2000
2160 REM ' ************************** PICK THREE **********************************
2200 GOSUB 37400
2240 LOCATE 10,12:PRINT "     Send Pick 3 Numbers to (S)creen -or- (P)rinter";
2280 GOSUB 37640
2320 AK$ = INKEY$: IF AK$ = "" THEN 2320
2360 IF AK$ = "P" OR AK$ = "p" THEN 3400
2400 IF AK$ = "S" OR AK$ = "s" THEN 2480
2440 BEEP: GOTO 2320
2480 GOSUB 37400
2520 REM color 1,0
2560 LOCATE 9,36:PRINT "PICK THREE "
2600 LOCATE 10,25:PRINT STRING$(30, 205)
2640 RANDOMIZE TIMER
2680 A% = INT(RND * 9)
2720 B% = INT(RND * 9)
2760 C% = INT(RND * 9)
2800 SUM% = A% + B% + C%
2840 LOCATE 12,36: PRINT "   " A%
2880 LOCATE 13,36: PRINT "   " B%
2920 LOCATE 14,36: PRINT "   " C%
2960 LOCATE 15,32:PRINT"___________"
3000 LOCATE 16,34: PRINT"SUM:"
3040 LOCATE 16,39: PRINT SUM%
3080 LOCATE 18,25:PRINT STRING$(30, 205)
3120 LOCATE 20,25:PRINT "MORE <N>UMBERS - - MAIN <M>ENU "
3160 GOSUB 37640
3200 B$ = INKEY$: IF B$ = "" THEN 3200
3240 IF B$ = "M" OR B$ = "m" THEN 920
3280 IF B$ = "N" OR B$ = "n" THEN 2480
3320 BEEP:GOTO 3200
3360 REM ' ******************* PICK THREE PRINTER FUNCTION *************"
3400 GOSUB 37400
3440 GOSUB 37640
3480 GOSUB 36960
3520 LOCATE 20,2:PRINT"HOW MANY TICKETS DO YOU WANT ";:INPUT N
3560 PRINT : PRINT " Printing in Progress:                                          "
3600 FOR T = 1 TO N
3640 LPRINT "    PICK__THREE
3680 FOR X = 1 TO 3
3720 RANDOMIZE TIMER
3760 L(X) = INT(RND * 9)
3800 NEXT X
3840 LPRINT "------------------------------------
3880 LPRINT "      PICK # 1 = "; L(1); L(2); L(3)
3920 ' LPRINT "      PICK # 2 = "; L(2)
3960 ' LPRINT "      PICK # 3 = "; L(3)
4000 LPRINT "------------------------------------
4040 NEXT T 
4080 COLOR 13, 0: LOCATE 20, 1: PRINT " Printing Operation Completed                                 "
4120 LOCATE 22, 1: PRINT " Select......Print More New (N)umbers, (M)ain Menu  ";: GOSUB 37640
4160 B$ = INKEY$: IF B$ = "" THEN 4160
4200 IF B$ = "M" OR B$ = "m" THEN 920
4240 IF B$ = "N" OR B$ = "n" THEN 3400
4280 BEEP:GOTO 4160
4320 REM ' ************************** PICK FOUR **********************************
4360 GOSUB 37400
4400 COLOR 2, 0:LOCATE 10,12:PRINT "     Send Pick 4 Numbers to (S)creen -or- (P)rinter";
4440 GOSUB 37640
4480 AK$ = INKEY$: IF AK$ = "" THEN 4480
4520 IF AK$ = "P" OR AK$ = "p" THEN 5600
4560 IF AK$ = "S" OR AK$ = "s" THEN 4640
4600 BEEP: GOTO 4480
4640 GOSUB 37400
4680 COLOR 2, 0:LOCATE 9,36:PRINT "PICK FOUR "
4720 LOCATE 10,25:PRINT STRING$(30, 205)
4760 RANDOMIZE TIMER
4800 A% = INT(RND * 9)
4840 B% = INT(RND * 9)
4880 C% = INT(RND * 9)
4920 D% = INT(RND * 9)
4960 SUM% = A% + B% + C% + D%
5000 LOCATE 12,34: PRINT "   " A%
5040 LOCATE 13,34: PRINT "   " B%
5080 LOCATE 14,34: PRINT "   " C%
5120 LOCATE 15,34: PRINT "   " D%
5160 LOCATE 16,29:PRINT"_____________"
5200 LOCATE 17,32: PRINT"SUM:"
5240 LOCATE 17,37: PRINT SUM%
5280 LOCATE 19,25:PRINT STRING$(30, 205)
5320 LOCATE 20,25:PRINT "MORE <N>UMBERS - - MAIN <M>ENU "
5360 GOSUB 37640
5400 B$ = INKEY$: IF B$ = "" THEN 5400
5440 IF B$ = "M" OR B$ = "m" THEN 920
5480 IF B$ = "N" OR B$ = "n" THEN 4640
5520 BEEP:GOTO 5400
5560 REM ' *************************** PICK FOUR PRINTER FUNCTION *************"
5600 GOSUB 37400
5640 GOSUB 37640
5680 GOSUB 36960
5720 LOCATE 20,2:PRINT"HOW MANY TICKETS DO YOU WANT ";:INPUT D
5760 PRINT : PRINT " Printing in Progress:                                          "
5800 FOR T = 1 TO D
5840 LPRINT "      PICK_FOUR "
5880 FOR X = 1 TO 4
5920 RANDOMIZE TIMER
5960 L(X) = INT(RND * 9)
6000 NEXT X
6040 LPRINT "-----------------------------------------
6080 LPRINT "      PICK # 1 = "; L(1); L(2); L(3); L(4)
6120 ' LPRINT "      PICK # 2 = "; L(2)
6160 ' LPRINT "      PICK # 3 = "; L(3)
6200 ' LPRINT "      PICK # 4 = "; L(4)
6240 LPRINT "-----------------------------------------
6280 NEXT T
6320 COLOR 3, 0: LOCATE 20, 1: PRINT " Printing Operation Completed                                 "
6360 LOCATE 22, 1: PRINT " Select.......Print More New (N)umbers, (M)ain Menu  ";: GOSUB 37640
6400 B$ = INKEY$: IF B$ = "" THEN 6400
6440 IF B$ = "M" OR B$ = "m" THEN 920
6480 IF B$ = "N" OR B$ = "n" THEN 5600
6520 BEEP:GOTO 6400
6560 REM ' *********************** CASH FIVE *************************************
6600 GOSUB 37400 
6640 COLOR 3, 0:LOCATE 12,12:PRINT "  Send CASH FIVE 35 Numbers to (S)creen -or- (P)rinter";
6680 GOSUB 37640
6720 AK$ = INKEY$: IF AK$ = "" THEN 6720
6760 IF AK$ = "P" OR AK$ = "p" THEN 7800
6800 IF AK$ = "S" OR AK$ = "s" THEN 6880
6840 BEEP: GOTO 6720
6880 GOSUB 37400
6920 COLOR 3, 0:LOCATE 9,31:PRINT "TEXAS CASH FIVE 35"
6960 LOCATE 10,25:PRINT STRING$(30, 205)
7000 FOR X = 1 TO 5
7040 RANDOMIZE TIMER
7080 L(X) = INT(RND * 35) + 1
7120 IF X > 1 THEN 7160 ELSE 7240
7160 FOR Y = 1 TO X - 1: IF L(X) = L(Y) THEN 7040
7200 NEXT Y
7240 NEXT X
7280 LOCATE 12,33:PRINT "PICK # 1 = "; L(1)
7320 LOCATE 13,33:PRINT "PICK # 2 = "; L(2)
7360 LOCATE 14,33:PRINT "PICK # 3 = "; L(3)
7400 LOCATE 15,33:PRINT "PICK # 4 = "; L(4)
7440 LOCATE 16,33:PRINT "PICK # 5 = "; L(5)
7480 LOCATE 18,25:PRINT STRING$(30, 205)
7520 LOCATE 19,25:PRINT "MORE <N>UMBERS - - MAIN <M>ENU";
7560 GOSUB 37640
7600 B$ = INKEY$: IF B$ = "" THEN 7600
7640 IF B$ = "M" OR B$ = "m" THEN 920
7680 IF B$ = "N" OR B$ = "n" THEN 6880
7720 BEEP:GOTO 7600
7760 REM ' *********************** CASH FIVE PRINT FUNCTION ***********************
7800 GOSUB 37400
7840 GOSUB 37640
7880 GOSUB 36960
7920 LOCATE 20,2:PRINT"HOW MANY TICKETS DO YOU WANT  ";:INPUT E
7960 PRINT : PRINT " Printing in Progress:                                          "
8000 FOR T = 1 TO E
8040 LPRINT "      CASH_FIVE_35"
8080 FOR X = 1 TO 5
8120 RANDOMIZE TIMER
8160 L(X) = INT(RND * 35) + 1
8200 IF X > 1 THEN 8240 ELSE 8320
8240 FOR Y = 1 TO X - 1: IF L(X) = L(Y) THEN 8120
8280 NEXT Y
8320 NEXT X
8360 LPRINT "-----------------------------------------------
8400 LPRINT "      PICK # 1 = "; L(1); L(2); L(3); L(4); L(5)
8440 ' LPRINT "      PICK # 2 = "; L(2)
8480 ' LPRINT "      PICK # 3 = "; L(3)
8520 ' LPRINT "      PICK # 4 = "; L(4)
8560 ' LPRINT "      PICK # 5 = "; L(5)
8600 LPRINT "-----------------------------------------------
8640 NEXT T
8680 COLOR 3, 0: LOCATE 20, 1: PRINT " Printing Operation Completed                                 "
8720 LOCATE 22, 1: PRINT " Select.......Print More New (N)umbers, (M)ain Menu  ";: GOSUB 37640
8760 B$ = INKEY$: IF B$ = "" THEN 8760
8800 IF B$ = "M" OR B$ = "m" THEN 920
8840 IF B$ = "N" OR B$ = "n" THEN 7800
8880 BEEP:GOTO 8760
8920 REM ' ****************** POWER BALL ***********************************
8960 GOSUB 37400
9000 COLOR 7, 0:LOCATE 10,30:PRINT "TEXAS POWER BALL 69/26"; :LOCATE 19,23:PRINT STRING$(34, 205):LOCATE 11,23:PRINT STRING$(34, 205)
9040 COLOR 7, 0:LOCATE 13,32:PRINT "(W)ITH POWER BALL": LOCATE 15,32:PRINT "(N)O POWER BALL"; :LOCATE 17,32:PRINT "(P)OWER BALL ONLY";
9080 GOSUB 37640
9120 AK$ = INKEY$: IF AK$ = "" THEN 9120
9160 IF AK$ = "W" OR AK$ = "w" THEN 9320
9200 IF AK$ = "N" OR AK$ = "n" THEN 13280
9240 IF AK$ = "P" OR AK$ = "p" THEN 10840
9280 BEEP:GOTO 9120
9320 GOSUB 37400 
9360 COLOR 7, 0:LOCATE 10,12:PRINT "Send POWER BALL Numbers 69/26 to (S)creen -or- (P)rinter";
9400 GOSUB 37640
9440 AK$ = INKEY$: IF AK$ = "" THEN 9440
9480 IF AK$ = "P" OR AK$ = "p" THEN 11760
9520 IF AK$ = "S" OR AK$ = "s" THEN 9600
9560 BEEP: GOTO 9440
9600 GOSUB 37400
9640 COLOR 7, 0:LOCATE 9,30:PRINT " POWER BALL   69/26 "
9680 LOCATE 10,25:PRINT STRING$(30, 205)
9720 FOR X = 1 TO 5
9760 RANDOMIZE TIMER
9800 W(X) = INT(RND * 69) + 1
9840 IF X > 1 THEN 9880 ELSE 9960
9880 FOR Y = 1 TO X - 1: IF W(X) = W(Y) THEN 9760
9920 NEXT Y
9960 NEXT X
10000 LOCATE 12,34:PRINT "PICK # 1 = "; W(1)
10040 LOCATE 13,34:PRINT "PICK # 2 = "; W(2)
10080 LOCATE 14,34:PRINT "PICK # 3 = "; W(3)
10120 LOCATE 15,34:PRINT "PICK # 4 = "; W(4)
10160 LOCATE 16,34:PRINT "PICK # 5 = "; W(5)
10200 LOCATE 17,25:PRINT STRING$(30, 205)
10240 FOR X = 1 TO 1
10280 RANDOMIZE TIMER
10320 S(X) = INT(RND * 26) + 1
10360 IF (X) > 1 THEN 10400 ELSE 10480
10400 FOR Y = 1 TO X - 1: IF S(X) = S(Y) THEN 10280
10440 NEXT Y
10480 NEXT X
10520 LOCATE 18,30:PRINT " POWER BALL # = "; S(1)
10560 LOCATE 21,25:PRINT "MORE <N>UMBERS - - MAIN <M>ENU ";
10600 GOSUB 37640
10640 B$ = INKEY$: IF B$ = "" THEN 10640
10680 IF B$ = "M" OR B$ = "m" THEN 920
10720 IF B$ = "N" OR B$ = "n" THEN 9600
10760 BEEP:GOTO 10640
10800 REM ' ****************** POWER BALL POWER PLAY ONLY *****************
10840 GOSUB 37400 
10880 COLOR 7, 0:LOCATE 10,12:PRINT "Send POWER BALL Numbers 69/26 to (S)creen -or- (P)rinter";
10920 GOSUB 37640
10960 AK$ = INKEY$: IF AK$ = "" THEN 10960
11000 IF AK$ = "P" OR AK$ = "p" THEN 15640
11040 IF AK$ = "S" OR AK$ = "s" THEN 11120
11080 BEEP: GOTO 10960
11120 GOSUB 37400:COLOR 7, 0:LOCATE 10,30:PRINT "TEXAS POWER PLAY 69/26"; :LOCATE 19,23:PRINT STRING$(34, 205):LOCATE 11,23:PRINT STRING$(34, 205)
11160 FOR X = 1 TO 1
11200 RANDOMIZE TIMER
11240 S(X) = INT(RND * 26) + 1
11280 IF (X) > 1 THEN 11320 ELSE 11400
11320 FOR Y = 1 TO X - 1: IF S(X) = S(Y) THEN 11360
11360 NEXT Y
11400 NEXT X
11440 LOCATE 15,30:PRINT " POWER BALL # = "; S(1)
11480 LOCATE 21,25:PRINT "MORE <N>UMBERS - - MAIN <M>ENU ";
11520 GOSUB 37640
11560 B$ = INKEY$: IF B$ = "" THEN 11560
11600 IF B$ = "M" OR B$ = "m" THEN 920
11640 IF B$ = "N" OR B$ = "n" THEN 11000
11680 BEEP:GOTO 11560
11720 REM ' ****************** POWER BALL FULL PRINT FUNCTION ******************
11760 GOSUB 37400
11800 GOSUB 37640
11840 GOSUB 36960
11880 LOCATE 20,2: PRINT"HOW MANY TICKETS DO YOU WANT  ";:INPUT F
11920 PRINT : PRINT " Printing in Progress:                                          "
11960 FOR T = 1 TO F
12000 LPRINT "      POWER_BALL_69/26"
12040 FOR X = 1 TO 5
12080 RANDOMIZE TIMER
12120 W(X) = INT(RND * 69) + 1
12160 IF X > 1 THEN 12200 ELSE 12280
12200 FOR Y = 1 TO X - 1: IF W(X) = W(Y) THEN 12080
12240 NEXT Y
12280 NEXT X
12320 LPRINT "-----------------------------------------------
12360 LPRINT "      PICK # 1 = "; W(1); W(2); W(3); W(4); W(5)
12400 ' LPRINT "      PICK # 2 = "; W(2)
12440 ' LPRINT "      PICK # 3 = "; W(3)
12480 ' LPRINT "      PICK # 4 = "; W(4)
12520 ' LPRINT "      PICK # 5 = "; W(5)
12560 ' LPRINT "---------------------------------------------
12600 FOR X = 1 TO 1
12640 RANDOMIZE TIMER
12680 S(X) = INT(RND * 26) + 1
12720 IF (X) > 1 THEN 12760 ELSE 12840
12760 FOR Y = 1 TO X - 1: IF S(X) = S(Y) THEN 12640
12800 NEXT Y
12840 NEXT X
12880 LPRINT "      POWER_BALL # "; S(1)
12920 LPRINT "-----------------------------------------------
12960 NEXT T
13000 LOCATE 20, 1: COLOR 7, 0 : PRINT " Printing Operation Completed                                 "
13040 LOCATE 22, 1: PRINT " Select.......Print More New (N)umbers, (M)ain Menu  ";: GOSUB 37640
13080 B$ = INKEY$: IF B$ = "" THEN 13080
13120 IF B$ = "M" OR B$ = "m" THEN 920
13160 IF B$ = "N" OR B$ = "n" THEN 11760
13200 BEEP:GOTO 13080
13240 REM ' ************* POWER BALL NO POWER PLAY *****************************
13280 GOSUB 37400
13320 COLOR 7, 0:LOCATE 10,12:PRINT "     Send POWER BALL 69/26 to (S)creen -or- (P)rinter";
13360 GOSUB 37640
13400 AK$ = INKEY$: IF AK$ = "" THEN 13400
13440 IF AK$ = "P" OR AK$ = "p" THEN 14480
13480 IF AK$ = "S" OR AK$ = "s" THEN 13560
13520 BEEP: GOTO 13400
13560 GOSUB 37400
13600 COLOR 7, 0:LOCATE 9,25:PRINT "POWER BALL 69/26 NO POWER PLAY"
13640 LOCATE 10,23:PRINT STRING$(34, 205)
13680 FOR X = 1 TO 5
13720 RANDOMIZE TIMER
13760 L(X) = INT(RND * 69) + 1
13800 IF X > 1 THEN 13840 ELSE 13920
13840 FOR Y = 1 TO X - 1: IF L(X) = L(Y) THEN 13720
13880 NEXT Y
13920 NEXT X
13960 LOCATE 12,34:PRINT "PICK # 1 = "; L(1)
14000 LOCATE 13,34:PRINT "PICK # 2 = "; L(2)
14040 LOCATE 14,34:PRINT "PICK # 3 = "; L(3)
14080 LOCATE 15,34:PRINT "PICK # 4 = "; L(4)
14120 LOCATE 16,34:PRINT "PICK # 5 = "; L(5)
14160 LOCATE 18,23:PRINT STRING$(34, 205)
14200 LOCATE 19,25:PRINT "MORE <N>UMBERS - - MAIN <M>ENU";
14240 GOSUB 37640
14280 B$ = INKEY$: IF B$ = "" THEN 14280
14320 IF B$ = "M" OR B$ = "m" THEN 920
14360 IF B$ = "N" OR B$ = "n" THEN 13560
14400 BEEP:GOTO 14280
14440 REM ' ************* POWER BALL NO POWER BALL PRINTER FUNCTION ******************
14480 GOSUB 37400
14520 GOSUB 37640
14560 GOSUB 36960
14600 LOCATE 20,2: PRINT"HOW MANY TICKETS DO YOU WANT  ";:INPUT F
14640 PRINT : PRINT " Printing in Progress:                                          "
14680 FOR T = 1 TO F
14720 LPRINT "       POWER_BALL_W/O_POWER_PLAY_69/26"
14760 FOR X = 1 TO 5
14800 RANDOMIZE TIMER
14840 L(X) = INT(RND * 69) + 1
14880 IF X > 1 THEN 14920 ELSE 15000
14920 FOR Y = 1 TO X - 1: IF L(X) = L(Y) THEN 14800
14960 NEXT Y
15000 NEXT X
15040 LPRINT "------------------------------------------
15080 LPRINT "      PICK # 1 = " ;L(1); L(2); L(3); L(4); L(5)
15120 ' LPRINT "      PICK # 2 = " ;L(2)
15160 ' LPRINT "      PICK # 3 = " ;L(3)
15200 ' LPRINT "      PICK # 4 = " ;L(4)
15240 ' LPRINT "      PICK # 5 = " ;L(5)
15280 LPRINT "------------------------------------------
15320 NEXT T
15360 LOCATE 20, 1: COLOR 7, 0 : PRINT " Printing Operation Completed                                 "
15400 LOCATE 22, 1: PRINT " Select.......Print More New (N)umbers, (M)ain Menu  ";: GOSUB 37640
15440 B$ = INKEY$: IF B$ = "" THEN 15440
15480 IF B$ = "M" OR B$ = "m" THEN 920
15520 IF B$ = "N" OR B$ = "n" THEN 14480
15560 BEEP:GOTO 15440
15600 REM ' ****************** POWER BALL POWER PLAY ONLY PRINT **************
15640 GOSUB 37400
15680 GOSUB 37640
15720 GOSUB 36960
15760 LOCATE 20,2: PRINT"HOW MANY TICKETS DO YOU WANT  ";:INPUT F
15800 PRINT : PRINT " Printing in Progress:                                          "
15840 FOR T = 1 TO F
15880 LPRINT "     POWER_BALL_POWER_PLAY_69/26"
15920 FOR X = 1 TO 1
15960 RANDOMIZE TIMER
16000 L(X) = INT(RND * 26) + 1
16040 IF X > 1 THEN 16080 ELSE 16160
16080 FOR Y = 1 TO X - 1: IF L(X) = L(Y) THEN 15960
16120 NEXT Y
16160 NEXT X
16200 LPRINT "----------------------------------
16240 LPRINT "      POWER BALL #  = " ;L(1)
16280 LPRINT "----------------------------------
16320 NEXT T
16360 LOCATE 20, 1: COLOR 7, 0 : PRINT " Printing Operation Completed                                 "
16400 LOCATE 22, 1: PRINT " Select.......Print More New (N)umbers, (M)ain Menu  ";: GOSUB 37640
16440 B$ = INKEY$: IF B$ = "" THEN 16440
16480 IF B$ = "M" OR B$ = "m" THEN 920
16520 IF B$ = "N" OR B$ = "n" THEN 15640
16560 BEEP:GOTO 16440
16600 REM ' ****************** MEGA MILLION ***********************************
16640 GOSUB 37400
16680 LOCATE 10,31:PRINT "TEXAS MEGA MILLION 70/25"; :LOCATE 19,23:PRINT STRING$(34, 205):LOCATE 11,23:PRINT STRING$(34, 205)
16720 LOCATE 13,32:PRINT "(W)ITH MEGA BALL": LOCATE 15,32:PRINT "(N)O MEGA BALL"; :LOCATE 17,32:PRINT "(M)EGA BALL ONLY";
16760 GOSUB 37640
16800 AK$ = INKEY$: IF AK$ = "" THEN 16800
16840 IF AK$ = "W" OR AK$ = "w" THEN 17000
16880 IF AK$ = "N" OR AK$ = "n" THEN 20920
16920 IF AK$ = "M" OR AK$ = "m" THEN 18480
16960 BEEP:GOTO 16800
17000 GOSUB 37400
17040 LOCATE 10,12:PRINT "Send MEGA MILLION Numbers 70/25 to (S)creen -or- (P)rinter";
17080 GOSUB 37640
17120 AK$ = INKEY$: IF AK$ = "" THEN 17120
17160 IF AK$ = "P" OR AK$ = "p" THEN 19440
17200 IF AK$ = "S" OR AK$ = "s" THEN 17280
17240 BEEP: GOTO 17120
17280 GOSUB 37400
17320 LOCATE 9,25:PRINT "   TEXAS MEGA MILLION  70/25"
17360 LOCATE 10,25:PRINT STRING$(31, 205)
17400 FOR X = 1 TO 5
17440 RANDOMIZE TIMER
17480 W(X) = INT(RND * 70) + 1
17520 IF X > 1 THEN 17560 ELSE 17640
17560 FOR Y = 1 TO X - 1: IF W(X) = W(Y) THEN 17440
17600 NEXT Y
17640 NEXT X
17680 LOCATE 12,34:PRINT "PICK # 1 = "; W(1)
17720 LOCATE 13,34:PRINT "PICK # 2 = "; W(2)
17760 LOCATE 14,34:PRINT "PICK # 3 = "; W(3)
17800 LOCATE 15,34:PRINT "PICK # 4 = "; W(4)
17840 LOCATE 16,34:PRINT "PICK # 5 = "; W(5)
17880 LOCATE 17,25:PRINT STRING$(31, 205)
17920 FOR X = 1 TO 1
17960 RANDOMIZE TIMER
18000 S(X) = INT(RND * 25) + 1
18040 IF (X) > 1 THEN 18080 ELSE 18160
18080 FOR Y = 1 TO X - 1: IF S(X) = S(Y) THEN 17960
18120 NEXT Y
18160 NEXT X
18200 LOCATE 18,32:PRINT "MEGA BALL # = "; S(1)
18240 LOCATE 21,25:PRINT "MORE <N>UMBERS - -  MAIN <M>ENU ";
18280 GOSUB 37640
18320 B$ = INKEY$: IF B$ = "" THEN 18320
18360 IF B$ = "M" OR B$ = "m" THEN 920
18400 IF B$ = "N" OR B$ = "n" THEN 17280
18440 BEEP:GOTO 18320
18480 REM ' ***************** MEGA MILLION MEGA BALL ONLY ******************
18520 GOSUB 37400: LOCATE 10,12:PRINT "Send MEGA MILLION Numbers 70/25 to (S)creen -or- (P)rinter";
18560 GOSUB 37640
18600 BK$ = INKEY$: IF BK$ = "" THEN 18600
18640 IF BK$ = "S" OR BK$ = "s" THEN 18760
18680 IF BK$ = "P" OR BK$ = "p" THEN 23240
18720 BEEP:GOTO 18600
18760 CLS: GOSUB 37400: LOCATE 17,25:PRINT STRING$(31, 205)
18800 LOCATE 10,31:PRINT "TEXAS MEGA BALLS 70/25 "; :LOCATE 11,25:PRINT STRING$(31, 205)  
18840 FOR X = 1 TO 1
18880 RANDOMIZE TIMER
18920 S(X) = INT(RND * 25) + 1
18960 IF (X) > 1 THEN 19000 ELSE 19080
19000 FOR Y = 1 TO X - 1: IF S(X) = S(Y) THEN 18880
19040 NEXT Y
19080 NEXT X
19120 LOCATE 15,33:PRINT "MEGA BALL # = "; S(1)
19160 LOCATE 21,25:PRINT "MORE <N>UMBERS - -  MAIN <M>ENU ";
19200 GOSUB 37640
19240 B$ = INKEY$: IF B$ = "" THEN 19240
19280 IF B$ = "M" OR B$ = "m" THEN 920
19320 IF B$ = "N" OR B$ = "n" THEN 18760
19360 BEEP:GOTO 19240
19400 REM ' ****************** MEGA MILLION PRINT FUNCTION with MEGA BALL ******************
19440 GOSUB 37400
19480 GOSUB 36960
19520 LOCATE 20,2:PRINT"HOW MANY TICKETS DO YOU WANT  ";:INPUT N
19560 PRINT : PRINT " Printing in Progress:                                          "
19600 FOR T = 1 TO N
19640 LPRINT "    MEGA_MILLION_70/25
19680 FOR X = 1 TO 5
19720 RANDOMIZE TIMER
19760 W(X) = INT(RND * 70) + 1
19800 IF X > 1 THEN 19840 ELSE 19920
19840 FOR Y = 1 TO X - 1: IF W(X) = W(Y) THEN 19720
19880 NEXT Y
19920 NEXT X
19960 LPRINT "---------------------------------------
20000 LPRINT "      PICK # 1 = " ; W(1); W(2); W(3); W(4); W(5)
20040 ' LPRINT "      PICK # 2 = " ; W(2)
20080 ' LPRINT "      PICK # 3 = " ; W(3)
20120 ' LPRINT "      PICK # 4 = " ; W(4)
20160 ' LPRINT "      PICK # 5 = " ; W(5)
20200 FOR X = 1 TO 1
20240 RANDOMIZE TIMER
20280 S(X) = INT(RND * 25) + 1
20320 IF (X) > 1 THEN 20360 ELSE 20440
20360 FOR Y = 1 TO X - 1: IF S(X) = S(Y) THEN 20240
20400 NEXT Y
20440 NEXT X
20480 ' LPRINT "-------------------------------------
20520 LPRINT "      MEGA_BALL # "; S(1)
20560 LPRINT "---------------------------------------
20600 NEXT T 
20640 LOCATE 20, 1: COLOR 13 ,0:PRINT " Printing Operation Completed                                 "
20680 LOCATE 22, 1: PRINT " Select.......Print More New (N)umbers, (M)ain Menu  ";: GOSUB 37640
20720 B$ = INKEY$: IF B$ = "" THEN 20720
20760 IF B$ = "M" OR B$ = "m" THEN 920
20800 IF B$ = "N" OR B$ = "n" THEN 19440
20840 BEEP:GOTO 20720
20880 REM ' ************* MEGA MILLION NO MEGA BALL *****************************
20920 GOSUB 37400
20960 LOCATE 10,12:PRINT "Send MEGA MILLION 70/25 WITH NO MB to (S)creen -or- (P)rinter";
21000 GOSUB 37640
21040 AK$ = INKEY$: IF AK$ = "" THEN 21040
21080 IF AK$ = "P" OR AK$ = "p" THEN 22120
21120 IF AK$ = "S" OR AK$ = "s" THEN 21200
21160 BEEP: GOTO 21040
21200 GOSUB 37400
21240 LOCATE 9,22:PRINT "TEXAS MEGA MILLION 70/25 NO MEGABALL"
21280 LOCATE 10,21:PRINT STRING$(38, 205)
21320 FOR X = 1 TO 5
21360 RANDOMIZE TIMER
21400 L(X) = INT(RND * 70) + 1
21440 IF X > 1 THEN 21480 ELSE 21560
21480 FOR Y = 1 TO X - 1: IF L(X) = L(Y) THEN 21360
21520 NEXT Y
21560 NEXT X
21600 LOCATE 12,34:PRINT "PICK # 1 = "; L(1)
21640 LOCATE 13,34:PRINT "PICK # 2 = "; L(2)
21680 LOCATE 14,34:PRINT "PICK # 3 = "; L(3)
21720 LOCATE 15,34:PRINT "PICK # 4 = "; L(4)
21760 LOCATE 16,34:PRINT "PICK # 5 = "; L(5)
21800 LOCATE 18,21:PRINT STRING$(38, 205)
21840 LOCATE 19,25:PRINT "MORE <N>UMBERS - - MAIN <M>ENU";
21880 GOSUB 37640
21920 B$ = INKEY$: IF B$ = "" THEN 21920
21960 IF B$ = "M" OR B$ = "m" THEN 920
22000 IF B$ = "N" OR B$ = "n" THEN 21200
22040 BEEP:GOTO 21920
22080 REM ' *************  MEGA MILLION PRINTER FUNCTION WITH NO MEGABALL ******************
22120 GOSUB 37400
22160 GOSUB 36960
22200 LOCATE 20,2:PRINT"HOW MANY TICKETS DO YOU WANT  ";:INPUT N
22240 PRINT : PRINT " Printing in Progress:                                          "
22280 FOR T = 1 TO N
22320 LPRINT "  MEGA_MILLION_WITH_OUT_MEGABALL_70/25
22360 FOR X = 1 TO 5
22400 RANDOMIZE TIMER
22440 L(X) = INT(RND * 70) + 1
22480 IF X > 1 THEN 22520 ELSE 22600
22520 FOR Y = 1 TO X - 1: IF L(X) = L(Y) THEN 22400
22560 NEXT Y
22600 NEXT X
22640 LPRINT "----------------------------------------
22680 LPRINT "      PICK # 1 = ";L(1); L(2); L(3); L(4); L(5)
22720 ' LPRINT "      PICK # 2 = ";L(2)
22760 ' LPRINT "      PICK # 3 = ";L(3)
22800 ' LPRINT "      PICK # 4 = ";L(4)
22840 ' LPRINT "      PICK # 5 = ";L(5)
22880 LPRINT "----------------------------------------
22920 NEXT T
22960 LOCATE 20, 1: COLOR 13 ,0:PRINT " Printing Operation Completed                                 "
23000 LOCATE 22, 1: PRINT " Select.......Print More New (N)umbers, (M)ain Menu  ";: GOSUB 37640
23040 B$ = INKEY$: IF B$ = "" THEN 23040
23080 IF B$ = "M" OR B$ = "m" THEN 920
23120 IF B$ = "N" OR B$ = "n" THEN 22120
23160 BEEP:GOTO 23040
23200 REM ' ****************** MEGA MILLION PRINTER FUNCTION MEGABALL ONLY ************
23240 GOSUB 37400
23280 GOSUB 37640
23320 GOSUB 36960
23360 LOCATE 20,2:PRINT"HOW MANY TICKETS DO YOU WANT  ";:INPUT N
23400 PRINT : PRINT " Printing in Progress:"
23440 FOR T = 1 TO N
23480 LPRINT "  MEGA_MILLION_WITH_MEGABALL_ONLY_70/25
23520 FOR X = 1 TO 1
23560 RANDOMIZE TIMER
23600 L(X) = INT(RND * 25) + 1
23640 IF X > 1 THEN 23680 ELSE 23760
23680 FOR Y = 1 TO X - 1: IF L(X) = L(Y) THEN 23560
23720 NEXT Y
23760 NEXT X
23800 LPRINT "----------------------------------------
23840 LPRINT "       MEGABALL  #  = ";L(1)
23880 LPRINT "----------------------------------------
23920 NEXT T
23960 LOCATE 20, 1: COLOR 13 ,0:PRINT " Printing Operation Completed                                 "
24000 LOCATE 22, 1: PRINT " Select.......Print More New (N)umbers, (M)ain Menu  ";: GOSUB 37640
24040 B$ = INKEY$: IF B$ = "" THEN 24040
24080 IF B$ = "M" OR B$ = "m" THEN 920
24120 IF B$ = "N" OR B$ = "n" THEN 23240
24160 BEEP:GOTO  24040
24200 REM ' **************** TEXAS TWO STEP ********************************
24240 GOSUB 37400
24280 COLOR 6, 0:LOCATE 10,29:PRINT "TEXAS TWO STEP 35/35 "; :LOCATE 19,23:PRINT STRING$(34, 205):LOCATE 11, 23:PRINT STRING$(34, 205)
24320 LOCATE 13,32:PRINT "(W)ith BONUS BALL": LOCATE 15,32:PRINT "(N)O BONUS BALL"; :LOCATE 17,32:PRINT "(B)ONUS BALL ONLY";
24360 GOSUB 37640
24400 AK$ = INKEY$: IF AK$ = "" THEN 24400
24440 IF AK$ = "W" OR AK$ = "w" THEN 24600
24480 IF AK$ = "N" OR AK$ = "n" THEN 27560
24520 IF AK$ = "B" OR AK$ = "b" THEN 29840
24560 BEEP:GOTO 24400
24600 GOSUB 37400
24640 COLOR 6, 0:LOCATE 12,12:PRINT "   Send TEXAS TWO STEP 35/35 to (S)creen -or- (P)rinter";
24680 GOSUB 37640
24720 AK$ = INKEY$: IF AK$ = "" THEN 24720
24760 IF AK$ = "P" OR AK$ = "p" THEN 26080
24800 IF AK$ = "S" OR AK$ = "s" THEN 24880
24840 BEEP: GOTO 24720
24880 GOSUB 37400 
24920 COLOR 6, 0:LOCATE 9,30:PRINT "TEXAS TWO STEP 35/35"
24960 LOCATE 10,25:PRINT STRING$(30, 205)
25000 FOR X = 1 TO 4
25040 RANDOMIZE TIMER
25080 W(X) = INT(RND * 35) + 1
25120 IF X > 1 THEN 25160 ELSE 25240
25160 FOR Y = 1 TO X - 1: IF W(X) = W(Y) THEN 25040
25200 NEXT Y
25240 NEXT X
25280 LOCATE 12,34:PRINT "PICK # 1 = "; W(1)
25320 LOCATE 13,34:PRINT "PICK # 2 = "; W(2)
25360 LOCATE 14,34:PRINT "PICK # 3 = "; W(3)
25400 LOCATE 15,34:PRINT "PICK # 4 = "; W(4)
25440 LOCATE 16,25:PRINT STRING$(30, 205)
25480 FOR X = 1 TO 1
25520 RANDOMIZE TIMER
25560 S(X) = INT(RND * 35) + 1
25600 IF (X) > 1 THEN 25640 ELSE 25720
25640 FOR Y = 1 TO X - 1: IF S(X) = S(Y) THEN 25520
25680 NEXT Y
25720 NEXT X
25760 LOCATE 17,32:PRINT "BOUNS BALL # = "; S(1)
25800 LOCATE 19,25:PRINT "MORE <N>UMBERS - - MAIN <M>ENU ";
25840 GOSUB 37640
25880 B$ = INKEY$: IF B$ = "" THEN 25880
25920 IF B$ = "M" OR B$ = "m" THEN 920
25960 IF B$ = "N" OR B$ = "n" THEN 24880
26000 BEEP: GOTO 25880
26040 REM ' **************** TEXAS TWO STEP FULL PRINT FUNCTION ********************
26080 GOSUB 37400
26120 GOSUB 37640
26160 GOSUB 36960
26200 LOCATE 20,2:PRINT"HOW MANY TICKETS DO YOU WANT  ";:INPUT N
26240 PRINT : PRINT " Printing in Progress:                                          "
26280 FOR T = 1 TO N
26320 LPRINT "      TEXAS_TWO_STEP_35/35
26360 FOR X = 1 TO 4
26400 RANDOMIZE TIMER
26440 W(X) = INT(RND * 35) + 1
26480 IF X > 1 THEN 26520 ELSE 26600
26520 FOR Y = 1 TO X - 1: IF W(X) = W(Y) THEN 26400
26560 NEXT Y
26600 NEXT X
26640 LPRINT "----------------------------------
26680 LPRINT "      PICK # 1 = " ; W(1); W(2); W(3); W(4)
26720 ' LPRINT "      PICK # 2 = " ; W(2)
26760 ' LPRINT "      PICK # 3 = " ; W(3)
26800 ' LPRINT "      PICK # 4 = " ; W(4)
26840 RANDOMIZE TIMER
26880 FOR X = 1 TO 1
26920 S(X) = INT(RND * 35) + 1 
26960 IF (X) > 1 THEN 27000 ELSE 27080
27000 FOR Y = 1 TO X - 1: IF S(X) = S(Y) THEN 26840
27040 NEXT Y
27080 NEXT X
27120 LPRINT "-----------------------------------
27160 LPRINT "      BOUNS_BALL # " ; S(1)
27200 LPRINT "-----------------------------------
27240 NEXT T
27280 LOCATE 20, 1: COLOR 6, 0 : PRINT " Printing Operation Completed                                 "
27320 LOCATE 22, 1: PRINT " Select.......Print More New (N)umbers, (M)ain Menu  ";: GOSUB 37640
27360 B$ = INKEY$: IF B$ = "" THEN 27360
27400 IF B$ = "M" OR B$ = "m" THEN 920
27440 IF B$ = "N" OR B$ = "n" THEN 26080
27480 BEEP:GOTO 27360
27520 REM ' ******************  TEXAS TWO STEP WITH NO BONUS BALL ******************
27560 GOSUB 37400
27600 COLOR 6, 0:LOCATE 12,12:PRINT "     Send TEXAS TWO STEP 35/35 to (S)creen -or- (P)rinter";
27640 GOSUB 37640
27680 AK$ = INKEY$: IF AK$ = "" THEN 27680
27720 IF AK$ = "P" OR AK$ = "p" THEN 28720
27760 IF AK$ = "S" OR AK$ = "s" THEN 27840
27800 BEEP: GOTO 27680
27840 GOSUB 37400  
27880 COLOR 6, 0:LOCATE 9,30:PRINT "TEXAS TWO STEP 35/35"
27920 LOCATE 10,25:PRINT STRING$(30, 205)
27960 FOR X = 1 TO 4
28000 RANDOMIZE TIMER
28040 W(X) = INT(RND * 35) + 1
28080 IF X > 1 THEN 28120 ELSE 28200
28120 FOR Y = 1 TO X - 1: IF W(X) = W(Y) THEN 28000
28160 NEXT Y
28200 NEXT X
28240 LOCATE 12,34:PRINT "PICK # 1 = "; W(1)
28280 LOCATE 13,34:PRINT "PICK # 2 = "; W(2)
28320 LOCATE 14,34:PRINT "PICK # 3 = "; W(3)
28360 LOCATE 15,34:PRINT "PICK # 4 = "; W(4)
28400 LOCATE 17,25:PRINT STRING$(30, 205)
28440 LOCATE 18,25:PRINT "MORE <N>UMBERS - - MAIN <M>ENU ";
28480 GOSUB 37640
28520 B$ = INKEY$: IF B$ = "" THEN 28520
28560 IF B$ = "M" OR B$ = "m" THEN 920
28600 IF B$ = "N" OR B$ = "n" THEN 27840
28640 BEEP: GOTO 28520
28680 REM ' ************ TEXAS TWO STEP W/O BONUS BALL PRINT FUNCTION *****************
28720 GOSUB 37400
28760 GOSUB 37640
28800 GOSUB 36960
28840 LOCATE 20,2:PRINT"HOW MANY TICKETS DO YOU WANT  ";:INPUT N
28880 PRINT : PRINT " Printing in Progress:                                          "
28920 FOR T = 1 TO N
28960 LPRINT "      TEXAS_TWO_STEP_35/35
29000 FOR X = 1 TO 4
29040 RANDOMIZE TIMER
29080 W(X) = INT(RND * 35) + 1
29120 IF X > 1 THEN 29160 ELSE 29240
29160 FOR Y = 1 TO X - 1: IF W(X) = W(Y) THEN 29240
29200 NEXT Y
29240 NEXT X
29280 LPRINT "--------------------------------------
29320 LPRINT "      PICK # 1 = " ; W(1); W(2); W(3); W(4)
29360 ' LPRINT "      PICK # 2 = " ; W(2)
29400 ' LPRINT "      PICK # 3 = " ; W(3)
29440 ' LPRINT "      PICK # 4 = " ; W(4)
29480 LPRINT "--------------------------------------
29520 NEXT T
29560 LOCATE 20, 1: COLOR 6, 0 : PRINT " Printing Operation Completed                                 "
29600 LOCATE 22, 1: PRINT " Select.......Print More New (N)umbers, (M)ain Menu  ";: GOSUB 37640
29640 B$ = INKEY$: IF B$ = "" THEN 29640
29680 IF B$ = "M" OR B$ = "m" THEN 920
29720 IF B$ = "N" OR B$ = "n" THEN 28720
29760 BEEP:GOTO 29640
29800 REM ' ************ TEXAS TWO STEP BONUS BALL PRINT FUNCTION ONLY *****************
29840 GOSUB 37400
29880 COLOR 6, 0:LOCATE 12,12 :PRINT " Send TEXAS TWO STEP 35/35 to (S)creen -or- (P)rinter";
29920 GOSUB 37640
29960 AK$ = INKEY$: IF AK$ = "" THEN 29960
30000 IF AK$ = "P" OR AK$ = "p" THEN 30120
30040 IF AK$ = "S" OR AK$ = "s" THEN 31160
30080 BEEP: GOTO 29960
30120 GOSUB 37400
30160 GOSUB 37640
30200 GOSUB 36960
30240 LOCATE 20,2:PRINT"HOW MANY TICKETS DO YOU WANT  ";:INPUT N
30280 PRINT : PRINT " Printing in Progress:                                         "
30320 FOR T = 1 TO N
30360 LPRINT "      TEXAS_TWO_STEP_35/35
30400 FOR X = 1 TO 1
30440 RANDOMIZE TIMER
30480 W(X) = INT(RND * 35) + 1
30520 IF X > 1 THEN 30560 ELSE 30640
30560 FOR Y = 1 TO X - 1: IF W(X) = W(Y) THEN 30640
30600 NEXT Y
30640 NEXT X
30680 LPRINT "-------------------------------
30720 LPRINT "      BOUNS_BALL # " ; W(1)
30760 LPRINT "-------------------------------
30800 NEXT T
30840 GOSUB 37640
30880 LOCATE 20, 1:COLOR 6, 0 : PRINT " Printing Operation Completed                                 "
30920 LOCATE 22, 1: PRINT " Select.......Print More New (N)umbers, (M)ain Menu ";
30960 B$ = INKEY$: IF B$ = "" THEN 30960
31000 IF B$ = "M" OR B$ = "m" THEN 920
31040 IF B$ = "N" OR B$ = "n" THEN 30120
31080 BEEP:GOTO 30960
31120 '***************** TEXAS TWO STEP BONUS BALL ********************************
31160 GOSUB 37400  
31200 COLOR 6, 0:LOCATE 9,30:PRINT "TEXAS TWO STEP 35/35"
31240 LOCATE 10,25:PRINT STRING$(30, 205)
31280 FOR X = 1 TO 1
31320 RANDOMIZE TIMER
31360 W(X) = INT(RND * 35) + 1
31400 IF X > 1 THEN 31440 ELSE 31520
31440 FOR Y = 1 TO X - 1: IF W(X) = W(Y) THEN 31320
31480 NEXT Y
31520 NEXT X
31560 LOCATE 14,31:PRINT "BONUS BALL #  = "; W(1)
31600 LOCATE 17,25:PRINT STRING$(30, 205)
31640 LOCATE 18,25:PRINT "MORE <N>UMBERS - - MAIN <M>ENU ";
31680 GOSUB 37640
31720 B$ = INKEY$: IF B$ = "" THEN 31720
31760 IF B$ = "M" OR B$ = "m" THEN 920
31800 IF B$ = "N" OR B$ = "n" THEN 31160
31840 BEEP: GOTO 31720
31880 REM ' **************** TEXAS LOTTERY ***************************
31920 GOSUB 37400 
31960 COLOR 10, 0:LOCATE 10,12 :PRINT "  Send TEXAS LOTTERY 54 to (S)creen -or- (P)rinter";
32000 GOSUB 37640
32040 AK$ = INKEY$: IF AK$ = "" THEN 32040
32080 IF AK$ = "P" OR AK$ = "p" THEN 33160
32120 IF AK$ = "S" OR AK$ = "s" THEN 32200
32160 BEEP: GOTO 32040
32200 GOSUB 37400 
32240 COLOR 10, 0:LOCATE 9,32:PRINT "TEXAS LOTTERY  54"
32280 LOCATE 10,25:PRINT STRING$(30, 205)
32320 FOR X = 1 TO 6
32360 RANDOMIZE TIMER
32400 L(X) = INT(RND * 54) + 1
32440 IF X > 1 THEN 32480 ELSE 32560
32480 FOR Y = 1 TO X - 1: IF L(X) = L(Y) THEN 32360
32520 NEXT Y
32560 NEXT X
32600 LOCATE 12,34:PRINT "PICK # 1 = "; L(1)
32640 LOCATE 13,34:PRINT "PICK # 2 = "; L(2)
32680 LOCATE 14,34:PRINT "PICK # 3 = "; L(3)
32720 LOCATE 15,34:PRINT "PICK # 4 = "; L(4)
32760 LOCATE 16,34:PRINT "PICK # 5 = "; L(5)
32800 LOCATE 17,34:PRINT "PICK # 6 = "; L(6)
32840 LOCATE 20,25:PRINT STRING$(30, 205)
32880 LOCATE 21,25:PRINT "MORE <N>UMBERS - - MAIN <M>ENU ";
32920 GOSUB 37640
32960 B$ = INKEY$: IF B$ = "" THEN 32960
33000 IF B$ = "M" OR B$ = "m" THEN 920
33040 IF B$ = "N" OR B$ = "n" THEN  32200
33080 BEEP:GOTO 32960
33120 REM ' ************ TEXAS LOTTERY PRINTER FUNCTION ******************
33160 GOSUB 37400
33200 GOSUB 37640
33240 GOSUB 36960
33280 LOCATE 20,2:PRINT"HOW MANY TICKETS DO YOU WANT  ";:INPUT N
33320 PRINT : PRINT " Printing in Progress:"
33360 FOR T = 1 TO N
33400 LPRINT "      TEXAS_LOTTERY_54
33440 FOR X = 1 TO 6
33480 RANDOMIZE TIMER
33520 L(X) = INT(RND * 54) + 1
33560 IF X > 1 THEN 33600 ELSE 33680
33600 FOR Y = 1 TO X - 1: IF L(X) = L(Y) THEN 33480
33640 NEXT Y
33680 NEXT X
33720 LPRINT "----------------------------------------------
33760 LPRINT "      PICK # 1 = "; L(1); L(2); L(3); L(4); L(5); L(6)
33800 ' LPRINT "      PICK # 2 = "; L(2)
33840 ' LPRINT "      PICK # 3 = "; L(3)
33880 ' LPRINT "      PICK # 4 = "; L(4)
33920 ' LPRINT "      PICK # 5 = "; L(5)
33960 ' LPRINT "      PICK # 6 = "; L(6)
34000 LPRINT "----------------------------------------------
34040 GOSUB 37840 : NEXT T
34080 GOSUB 37640
34120 COLOR 10, 0: LOCATE 20, 1: PRINT " Printing Operation Completed                  "
34160 LOCATE 22, 1: PRINT " Select.......Print More New (N)umbers, (M)ain Menu ";
34200 B$ = INKEY$: IF B$ = "" THEN 34200
34240 IF B$ = "M" OR B$ = "m" THEN 920
34280 IF B$ = "N" OR B$ = "n" THEN 33160
34282 BEEP:GOTO 34200
34284 REM BBBBBBBBBBBBBBBBBBBBBBBBBBBBBB TEXAS TRIPLE CHOICE BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB
34286 REM GOSUB 37400 
34288 REM COLOR 10, 0:LOCATE 10,12 :PRINT "Send TEXAS TRIPLE CHOICE 55 to (S)creen -or- (P)rinter";
34290 REM GOSUB 37640
34292 REM AK$ = INKEY$: IF AK$ = "" THEN 34292
34294 REM IF AK$ = "P" OR AK$ = "p" THEN 34348
34296 REM IF AK$ = "S" OR AK$ = "s" THEN 34300
34298 REM BEEP: GOTO 34292
34300 REM GOSUB 37400 
34302 REM COLOR 10, 0:LOCATE 9,30:PRINT "TEXAS TRIPLE CHOICE 55"
34304 REM LOCATE 10,25:PRINT STRING$(30, 205)
34306 REM FOR X = 1 TO 7
34308 REM RANDOMIZE TIMER
34310 REM L(X) = INT(RND * 55) + 1
34312 REM IF X > 1 THEN 34314 ELSE 34318
34314 REM FOR Y = 1 TO X - 1: IF L(X) = L(Y) THEN 34308
34316 REM NEXT Y
34318 REM NEXT X
34320 REM LOCATE 12,34:PRINT "PICK # 1 = "; L(1)
34322 REM LOCATE 13,34:PRINT "PICK # 2 = "; L(2)
34324 REM LOCATE 14,34:PRINT "PICK # 3 = "; L(3)
34326 REM LOCATE 15,34:PRINT "PICK # 4 = "; L(4)
34328 REM LOCATE 16,34:PRINT "PICK # 5 = "; L(5)
34330 REM LOCATE 17,34:PRINT "PICK # 6 = "; L(6)
34331 REM LOCATE 18,34:PRINT "PICK # 7 = "; L(7)
34332 REM LOCATE 20,25:PRINT STRING$(30, 205)
34334 REM LOCATE 21,25:PRINT "MORE <N>UMBERS - - MAIN <M>ENU ";
34336 REM GOSUB 37640
34338 REM B$ = INKEY$: IF B$ = "" THEN 34338
34340 REM IF B$ = "M" OR B$ = "m" THEN 920
34342 REM IF B$ = "N" OR B$ = "n" THEN 34300
34344 REM BEEP:GOTO 34338
34346 REM REM ' ************ TEXAS TRIPLE CHOICE PRINTER FUNCTION ******************
34348 REM GOSUB 37400
34350 REM GOSUB 37640
34352 REM GOSUB 36960
34354 REM LOCATE 20,2:PRINT"HOW MANY TICKETS DO YOU WANT  ";:INPUT N
34356 REM PRINT : PRINT " Printing in Progress:"
34358 REM FOR T = 1 TO N
34360 REM LPRINT "    TEXAS_TRIPLE_CHOICE_55
34362 REM FOR X = 1 TO 7
34364 REM RANDOMIZE TIMER
34366 REM L(X) = INT(RND * 55) + 1
34367 REM IF X > 1 THEN 34368 ELSE 34370
34368 REM FOR Y = 1 TO X - 1: IF L(X) = L(Y) THEN 34364 
34369 REM NEXT Y
34370 REM NEXT X
34371 REM LPRINT "-------------------------------------------
34372 REM LPRINT "      PICK # 1 = "; L(1) L(2) L(3) L(4) L(5) L(6) L(7)
34373 ' LPRINT "      PICK # 2 = "; L(2)
34374 ' LPRINT "      PICK # 3 = "; L(3)
34375 ' LPRINT "      PICK # 4 = "; L(4)
34376 ' LPRINT "      PICK # 5 = "; L(5)
34377 ' LPRINT "      PICK # 6 = "; L(6)
34378 ' LPRINT "      PICK # 7 = "; L(7)
34379 REM LPRINT "-------------------------------------------
34380 REM GOSUB 37840 : NEXT T
34381 REM GOSUB 37640
34382 REM COLOR 10, 0: LOCATE 20, 1: PRINT " Printing Operation Completed                  "
34383 REM LOCATE 22, 1: PRINT " Select.......Print More New (N)umbers, (M)ain Menu ";
34384 REM B$ = INKEY$: IF B$ = "" THEN 34384
34385 REM IF B$ = "M" OR B$ = "m" THEN 920
34386 REM IF B$ = "N" OR B$ = "n" THEN 34348
34387 REM BEEP:GOTO 34384
34388 REM BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB
34390 ' KKKKKKKKKKKKKKKKKKKKK ALL OR NOTHING  KKKKKKKKKKKKKKKKKKKKKKKKKKKKKK
34400 GOSUB 37400
34440 COLOR 10, 0:LOCATE 10,12 :PRINT "  Send ALL or Nothing to (S)creen -or- (P)rinter";
34480 GOSUB 37640
34520 AK$ = INKEY$: IF AK$ = "" THEN 34520
34560 IF AK$ = "P" OR AK$ = "p" THEN 35880
34600 IF AK$ = "S" OR AK$ = "s" THEN 34680
34640 BEEP: GOTO 34520
34680 GOSUB 37400 
34720 COLOR 10, 0:LOCATE 9,36:PRINT "ALL or Nothing"
34760 LOCATE 10,25:PRINT STRING$(30, 205)
34800 FOR X = 1 TO 12
34840 RANDOMIZE TIMER
34880 L(X) = INT(RND * 24) + 1
34920 IF X > 1 THEN 34960 ELSE 35040
34960 FOR Y = 1 TO X - 1: IF L(X) = L(Y) THEN 34840
35000 NEXT Y
35040 NEXT X
35080 LOCATE 11,33:PRINT "PICK # 1  = "; L(1)
35120 LOCATE 12,33:PRINT "PICK # 2  = "; L(2)
35160 LOCATE 13,33:PRINT "PICK # 3  = "; L(3)
35200 LOCATE 14,33:PRINT "PICK # 4  = "; L(4)
35240 LOCATE 15,33:PRINT "PICK # 5  = "; L(5)
35280 LOCATE 16,33:PRINT "PICK # 6  = "; L(6)
35320 LOCATE 17,33:PRINT "PICK # 7  = "; L(7)
35360 LOCATE 18,33:PRINT "PICK # 8  = "; L(8)
35400 LOCATE 19,33:PRINT "PICK # 9  = "; L(9)
35440 LOCATE 20,33:PRINT "PICK # 10 = "; L(10)
35480 LOCATE 21,33:PRINT "PICK # 11 = "; L(11)
35520 LOCATE 22,33:PRINT "PICK # 12 = "; L(12)
35560 LOCATE 23,25:PRINT STRING$(30, 205)
35600 LOCATE 24,25:PRINT "MORE <N>UMBERS - - MAIN <M>ENU ";
35640 GOSUB 37640
35680 B$ = INKEY$: IF B$ = "" THEN 35680
35720 IF B$ = "M" OR B$ = "m" THEN 920
35760 IF B$ = "N" OR B$ = "n" THEN 34680
35800 BEEP:GOTO 35680
35840 ' KKKKKKKKKKKKKKKKKKKKKK ALL OR NOTHING PRINTER KKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKKK
35880 GOSUB 37400
35920 GOSUB 37640
35960 GOSUB 36960
36000 LOCATE 20,2:PRINT"HOW MANY TICKETS DO YOU WANT  ";:INPUT N
36040 PRINT : PRINT " Printing in Progress:"
36080 FOR T = 1 TO N
36120 LPRINT "    TEXAS_LOTTERY_ALL_OR_NOTHING
36160 FOR X = 1 TO 12
36200 RANDOMIZE TIMER
36240 L(X) = INT(RND * 24) + 1
36280 IF X > 1 THEN 36320 ELSE 36400
36320 FOR Y = 1 TO X - 1: IF L(X) = L(Y) THEN 36200
36360 NEXT Y
36400 NEXT X
36440 LPRINT "-------------------------------------------------------
36480 LPRINT "   PICK_#_1_THRU_6_= " ;  L(1); L(2); L(3); L(4); L(5); L(6)
36520 LPRINT "   PICK_#_6_THRU_12_= " ;  L(7); L(8); L(9); L(10); L(11); L(12)
36560 LPRINT "-------------------------------------------------------
36600 GOSUB 37840 : NEXT T
36640 GOSUB 37640
36680 COLOR 10, 0: LOCATE 20, 1: PRINT " Printing Operation Completed                  "
36720 LOCATE 22, 1: PRINT " Select.......Print More New (N)umbers, (M)ain Menu ";
36760 B$ = INKEY$: IF B$ = "" THEN 36760
36800 IF B$ = "M" OR B$ = "m" THEN 920
36840 IF B$ = "N" OR B$ = "n" THEN 35880
36880 BEEP:GOTO 36760
36920 REM ' *************************************************************************************
36960 LOCATE 10, 1: COLOR 15, 1: PRINT BOXIT$: LOCATE 11, 20: PRINT " Selections Being Sent Direct to Printer "
37000 COLOR 14, 0: PRINT : PRINT : PRINT " Make Sure Printer is Ready, Then Press Any Key.  ": COLOR 15, 0
37040 AK$ = INKEY$: IF AK$ = "" THEN 37080
37080 RETURN
37081 REM ' **********************************************************************************************
37085 CLS : LOCATE 1, 1: PRINT "";
37090 LOCATE 13, 20: PRINT " Do you Want to Continue ? (Y/N) ";
37095 AK$ = INKEY$: IF AK$ = "" THEN 37095
37100 IF AK$ = "N" OR AK$ = "n" THEN CLS : COLOR 15, 0: : SYSTEM : END
37102 IF AK$ = "Y" OR AK$ = "y" THEN RUN
37105 REM RUN
37108 RETURN
37120 CLS : LOCATE 1, 1: PRINT ""
37160 LOCATE 13, 20: PRINT "  Do you Really Want to QUIT ? (Y/N) ";
37200 GOSUB 37640
37240 AK$ = INKEY$: IF AK$ = "" THEN 37240
37280 IF AK$ = "Y" OR AK$ = "y" THEN CLS : COLOR 15, 0: SYSTEM : END
37282 IF AK$ = "N" OR AK$ = "n" THEN CLS : RUN
37320 REM RUN
37360 RETURN
37400 COLOR , 0: CLS : COLOR 15, 4: LOCATE 1, 1: PRINT BOXIT$
37440 LOCATE 2, 28: PRINT "T E X A S  <>  L O T T O
37480 COLOR 15, 1: LOCATE 5, 1: PRINT BOXIT$
37520 LOCATE 6, 25: PRINT "Picken'em with a PC Made Easy!
37560 LOCATE 4, 2:COLOR 2, 0:PRINT "Ver.8.6":LOCATE 4, 62: COLOR 2, 0: PRINT "F1=QUIT  F2=HELP": COLOR 13, 0
37600 RETURN
37640 COLOR 2, 0:LOCATE 25,27:PRINT DATE$,TIME$;
37680 RETURN
37720 LOCATE 4, 70: COLOR 2, 0 :PRINT " F1 = QUIT ": COLOR 12, 0:LOCATE 10,11:PRINT " DONE,  <F>ORM FEED OR PRINT MORE <N>UMBERS - MAIN <M>ENU ";
37760 RETURN
37800 FOR X = 1 TO 6
37840 RANDOMIZE TIMER
37880 RETURN
37920 IF X > 1 THEN 37960 ELSE 38040
37960 FOR Y = 1 TO X - 1: IF L(X) = L(Y) THEN 37960
38000 NEXT Y
38040 NEXT X

Leave a Reply

Your email address will not be published. Required fields are marked *