home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
CP/M
/
CPM_CDROM.iso
/
cpm
/
hamradio
/
novice1f.lbr
/
PRINTEST.BZS
/
PRINTEST.BAS
Wrap
BASIC Source File
|
1987-08-09
|
5KB
|
123 lines
0 DEFINT A-O:DIM A$(21),Q$(30):GOSUB 31
1 A$=INKEY$:PRINT:PRINT"PRESS ANY KEY TO CONTINUE":RANDOMIZE TIMER
2 WHILE A$=""
3 A$=INKEY$:RANDOMIZE TIMER
4 WEND
5 OPEN"O",2,"TEST.TXT"
6 FOR J=1 TO 30
7 WHILE A$<"X"
8 K=K+1:READ A$:A$(K)=A$
9 WEND
10 K=K-1:R=RND(0):I=R*K:IF I<1 THEN I=1 ELSE IF I>K THEN I=K
11 A$=A$(I):GOSUB 27
12 IF LEN(R$)=>LEN(Q$) AND LEFT$(R$,LEN(Q$))=Q$ THEN 17
13 LINE INPUT#1,R$
14 IF EOF(1) THEN Z=Z+1:GOSUB 30
15 IF Z>9 THEN CLOSE:PRINT"FILE ERRORS":END
16 GOTO 12
17 Q$(J)=LEFT$(Q$+" ",15)+RIGHT$(A$,1):PRINT Q$(J)
18 PRINT#2, R$:LINE INPUT#1,R$:IF INSTR(R$,CHR$(126))<1 THEN 18
19 I=J/3
20 I=I*3
21 IF I<>J THEN PRINT#2,"":PRINT#2,""
22 IF I=J THEN PRINT#2,CHR$(12)
23 K=0
24 NEXT J
25 FOR I=1 TO 30:PRINT#2,I;Q$(I):NEXT I:PRINT#2,CHR$(12)
26 CLOSE:SYSTEM
27 B$=MID$(A$,2,2):IF LEFT$(B$,1)="0" THEN B$=RIGHT$(B$,1)
28 C$=MID$(A$,4,2):IF LEFT$(C$,1)="0" THEN C$=RIGHT$(C$,1)
29 Q$="2"+LEFT$(A$,1)+"-"+B$+"."+C$:RETURN
30 PRINT"I AM HAVING TROUBLE FINDING FILE ";Q$;"PLEASE STAND-BY":CLOSE
31 OPEN "I",1,"NOVICE.DAT":RETURN
32 DATA A0101C,A0201B,A0301D,A0401A,A0501C,A0601B,A0701A,A0702D,A0801A,A0802B
33 DATA Z
34 DATA A0901B,A0902C,A0903A,A0904D,A0905D,A0906B,A0907B,A0908B,A0909A,A0910B
35 DATA A0911A,A0912B,A0913C,A0914C,Z
36 REM QUESTION 3
37 DATA A1001C,A1002C,A1003D,A1004C,A1005C,A1006A,A1007A,A1008A,A1009C,Z
38 REM QUESTION 4
39 DATA A1010B,A1011B,A1012C,A1013A,A1014A,A1015D,A1016A,A1017B,A1018B,A1019B
40 DATA A1020C,A1021B,A1022B,Z
41 REM QUESTION 5 A1101--->A1402
42 DATA A1101C,A1102D,A1103A,A1202B,A1202B,A1203B,A1301A,A1302C,A1401A,A1402D
43 DATA Z
44 REM QUESTION 6 A1501----->A1705
45 DATA A1501A,A1601D,A1602C,A1603D,A1604D,A1701D,A1702C,A1703D,A1704D,A1705D
46 DATA Z
47 REM QUESTION 7 A1801----->A1810
48 DATA A1801C,A1802B,A1803B,A1804A,A1805B,A1806B,A1807C,A1808D,A1809B,A1810A
49 DATA Z
50 REM QUESTION 8 A1901----->A2103
51 DATA A1901D,A1902C,A1903C,A1904C,A1905B,A1906C,A1907D,A1908B
52 DATA A2001C,A2002D,A2003D,A2101C,A2102C,A2103B
53 DATA Z
54 REM QUESTION 9
55 DATA A2201A,A2202C,A2203C,A2301B,A2302D,Z
56 REM QUESTION 10
57 DATA B0101B,B0102D,B0103A,B0201C,B0301A,B0302D,B0401C,B0501C,B0502B,B0503C
58 DATA B0601A,B0701B,B0702B,B0703C,B0704A,Z
59 REM QUESTION 11
60 DATA B0801C,B0802D,B0803A,B0804B,B0805D
61 DATA B0901A,B0902C,B0903D,B0904A,B0905B,B0906D,B0907A,B0908C
62 DATA B1001D,B1002A,B1003B,B1004C,B1005D,B1006B
63 DATA Z
64 REM QUESTION 12
65 DATA C0101A,C0102B,C0103A,C0104C,C0105D,C0106D
66 DATA C0201D,C0202B,C0203B,C0204A,Z
67 REM QUESTION 13
68 DATA C0301B,C0302B,C0401C,C0402C,C0403B,C0404A,C0405B,Z
69 REM QUESTION 14 D0101----->D0403
70 DATA D0101B,D0201D,D0202C,D0203D,D0301B,D0302A,D0303C,D0401D,D0402C,D0403D
71 DATA Z
72 REM QUESTION 15
73 DATA D0501B,D0502C,D0503B,D0504C
74 DATA D0601A,D0602A,D0603A,D0604C,D0605D,D0606B,Z
75 REM QUESTION 16
76 DATA D0701B,D0702C,D0703A,D0704C,D0705D
77 DATA D0706B,D0707D,D0708A,D0801A,D0802A,Z
78 REM QUESTION 17
79 DATA D0901B,D0902A,D0903C,D0904A,D0905B,D0906D
80 DATA D0907D,D0908D,D0909B,D0910B,D0911B,D0912B,Z
81 REM QUESTION 18
82 DATA E0101A,E0102D,E0103C
83 DATA E0202B,E0203C
84 DATA E0301A,E0302C,E0303C,Z
85 REM QUESTION 19 2E-4.1 -----> 2E-6.3
86 DATA E0401D,E0402C,E0501A,E0601B,E0602A,E0603C,Z
87 REM QUESTION 20
88 DATA E0701A,E0702D,E0703C,E0801A,E0802D,E0803A
89 DATA E0901B,E1001C,E1101B,Z
90 REM QUESTION 21
91 DATA E1201C,E1202A,E1301A,E1302C,E1303C
92 DATA E1304A,E1305D,E1306A,E1307D,E1308D,Z
93 REM QUESTION 22
94 DATA F0101C,F0103B,F0201C,F0202D,Z
95 REM QUESTION 23 3.1 3.2 3.3 DRAW SCHEMATIC
96 DATA F0401A,F0402D,Z
97 REM QUESTION 24
98 DATA G0102B,G0104D,G0202C,Z
99 REM QUESTION 25
100 DATA G0401C,G0501B,G0601B,G0602B,G0603C,Z
101 REM QUESTION 26
102 DATA H0101A,H0201B,H0202B,H0301B,H0302D
103 DATA H0401C,H0402C,H0501D,H0601A
104 DATA H0801B,H0802A,H0901C,H0902B,H1001C,H1002A,Z
105 REM QUESTION 27
106 DATA H1101A,H1102C,H1103B,H1104B,H1105D
107 DATA H1201C,H1202B,H1203B,H1204B,H1205A,Z
108 REM QUESTION 28
109 DATA I0101A,I0102D,I0103C,I0104C
110 DATA I0201D,I0202D,I0203B,I0204B,I0205A,Z
111 REM QUESTION 29
112 DATA I0206C,I0207B,I0301D,I0302B,I0303B,I0304B,I0305C,Z
113 REM QUESTION 30
114 DATA I0401B,I0402C,I0403D,I0404A,I0405B,I0501A,I0601B,I0605C,Z
115 IF A$="X" THEN CLOSE:END
116 PRINT"OOOPS YOU DIDN'T ENTER A B C D"
117 INPUT"ENTER 'X' TO eXit OR <ENTER> TO CONTINUE";Q$
118 IF Q$="X" THEN CLOSE:END
119 IF Q$="x" THEN CLOSE:END
120 RETURN
17 INPUT"ENTER 'X' TO eXit OR <ENTER> TO CONTINUE";Q$
118 IF Q$="