List Learning with the Sinclair

See all articles from SYNC v2 n5
Children watching a Sinclair computer display
Children watching a Sinclair computer display

Introduction

The Sinclair computers can be effective learning aids if the student or teacher has the software to set up learning situations. A program to assist in the learning process should meet several criteria. First, it should be self-explanatory. Second, it should have different modes of operation. Third, it should be practical as a learning tool. Fourth, it should be usable for various kinds of content. Fifth, it should be enjoyable to use. The List Learning Program discussed in this article meets these critera. Let’s look at this program and how you can use it to increase your learning or to help others over some of the hurdles of list learning.

Entering the Program

Type in the entire program in Listing 1. I would strongly urge saving your work frequently. Spending three hours at your Sinclair and having a power interrupt can be frustrating. After you have typed in and saved the entire program, congratulate yourself for your endurance!

Next, decide on the content for the list you want to use with the program. This list must consist of two columns in which the items to be memorized are paired. I originally designed the program for the list of the 92 natural elements and their symbols (this list can be found in any encyclopedia, usually under “The Periodic Law” or in any chemistry textbook). This is, of course, very valuable for anyone taking chemistry, but many other lists are possible, e.g., a list of states and abbreviations or capitals or other information.

Loading the Lists

When you have your two-column list prepared, enter it by following the steps listed below. For the sake of illustration, I will use the list of the 92 elements, so you will have to make the appropriate changes for your own list.

If you put your computer in FAST mode for entering the program, be sure to return to SLOW mode for entering your lists in order to avoid the screen flicker when the program starts running by itself later.

1) To get into the utility list loaded program, type GOTO 1000. NEVER, NEVER, NEVER, TYPE RUN in this program or you will lose your list.

2) A menu of the utility program’s functions will appear. Since you wish to load a new list, type in 1.

3) Input the title of your program which will appear when the program begins, e.g., “LEARNING THE ELEMENTS SYMBOLS.”

4) Type in the title of the first class of items in your list. This should be the class with the longest strings if applicable. In the list of elements the names of the elements are obviously longer than the symbols so you would type in “ELEMENT-“. If your list has two classes of items that are about the same (such as states and their capitals), it does not matter which is first.

5) The program now needs to know how many characters are in the longest word in the first class list. In the elements list this is 12.

6) Enter the name of the second class (“SYMBOL-“) and the length of the longest items (2).

7) Enter the number of items in your list (92 elements).

8) Now a display of everything you have typed in appears. If you have made a mistake, type N to start over.

9) To start entering the actual list, type Y. At the bottom of the screen a prompt will appear, e.g., “ELEMENT-“. Type in the first element “HYDROGEN,” and it will be displayed beside the prompt which will then scroll up to make room for the “SYMBOL-” prompt. Type in “H”, and the element prompt will reappear. Continue typing in the items until you have finished your list. If you see a mistake in something you have typed in, just finish the list.

10) After you finish typing in everything, the program will go into a review. The first pair of items will be displayed (ELEMENT-SYMBOL). If the pair is correct, hit ENTER to review the next pair. If either is incorrect, hit the X key and ENTER. The prompt for your first item will appear (ELEMENT-); type the entry in correctly. The prompt for the second item will appear (SYMBOL-); type in this entry correctly. The program then moves on to the next pair until all have been reviewed.

11) The program asks for the name that the program will be SAVEd under.

12) At this point you will return to the menu. If you want to review the list again to make changes or to doublecheck, type in 2. If you want to change the SAVE name, type in 3. If for some reason you want to start over, type in 1. To SAVE the program, hook up your recorder and position your tape where you wish to start. Hit 4 and ENTER and immediately hit the RECORD button. (If you used the elements list, the program will take 3:15 minutes to SAVE.)

13) After you have SAVEd the program, the utility program will put you into the actual learning program. Whenever you need to use the utility program again, simply type BREAK during a PAUSE and type GOTO 1000.

Now you can enjoy the fruits of your labor, but you must read the next section.

Using the Learning Program

When you LOAD the program or get out of the utility program by SAVEing, the list learning part of the program automatically starts. This prevents someone from being in a position to RUN it by accident.

The title of the list appears at the top of the screen, and a request to type in your name appears below it. This allows the computer to address you personally. Though this routine may be considered a frill, users may enjoy the feeling of a more personal interaction with the computer in a learning situation.

Program Modes

After typing in your name, you will see a program mode menu appear on the screen. This menu gives you four modes for using the lists you have entered.

Mode 1: Reviewing the List

The first mode is akin to running your finger down a list as you try to memorize it. However, when the computer does the moving, the situation is more involving and generally more effective. The program goes through the list in this manner: It flashes an item from the first list, pauses to allow the user time to remember the corresponding item from the second list, and then displays the second item. This procedure is more stimulating and helpful as a learning technique than simply displaying the pair of items simultaneously.

The speed of the display depends on the speed number you type in: 0 is the fastest and 9 is the slowest.

After you have gone through the items in the first list, the computer begins again with the items in the second list. When you have completed this list, the first list will again appear and the process endlessly repeats. So whenever you want to go back to menu, press the Q key. Sometimes you must press twice or thrice before the program responds. Entering Q will also exit you from modes 2 and 3.

Mode 2: Practice Drill

In the practice drill the program will randomly select 15 items from the first list and ask for the corresponding match. Then it will reverse the lists and again ask for the match. If your list has 40 items or more, the practice drill executes a special feature. Each time the drill is called up, an array E$ is used as a tally. If you answer a question correctly, the program “makes a note of it” and will not ask that item pair again. This tally is erased each time the practice drill mode is entered. Also, you will notice that, when you do not give a correct match, the program pauses longer after the correct answer is displayed. The additional time to look at the correct answer is a study feature. At the end of thirty questions, the number of correct answers is displayed.

Mode 3: Speed Quiz

In this mode you are given items from the longer list and asked for the matching item from the shorter list. You try to get as many of the pairs as possible in sixty seconds. This is the reason for making the second column shorter so that more questions can be answered in one minute. The computer gives you one point for each correct answer and penalizes you one point for each incorrect answer. If you have no idea what the answer is, hit ENTER. Inputting a null string in this way will move you on to the next question without penalty. After sixty seconds the program stops and displays your score.

Mode 4: Fond Farewell

The final mode is simply a “Fond Farewell” to the user. Instead of STOPping, the program will PAUSE about seventeen seconds and restart at the beginning. The purpose of this procedure is to prevent the user from accidentally RUNning it. This is also an ideal place to BREAK the program if you need to LIST it, modify it, or get into the utility program.

Program Features

This program provides you with a base for a custom program of your own. Not only can you use it for any two column list learning that you want, but also, with over 230 lines, you can tinker, change, and modify to your own satisfaction.

Subroutines are placed at the beginning of the program for faster execution. Most of the subroutines are only a line or two, but they do save memory. Let’s note the following subroutines especially.

Subroutine 10 is used to pick a random number and set up the screen. If a random number is not needed (as in the review mode), it is GOSUB 12.

Subroutine 15 is used in the review mode to test whether the user wants to exit. In modes 2 and 3 it is GOSUB 16.

Subroutine 20 is used in the first three modes in the initial display.

Subroutines 25 and 30 are used in the drill mode. The 8K ROM has an internal timer at memory locations 16436 and 16437 which PAUSE uses. It decrements every time a frame on the TV is displayed, i.e., sixty times a second. To time the speed drill, I POKEd the values to 0. The timer then starts counting backwards, beginning at 65536 and losing 60 a second. After each input, the computer PEEKs the value to see if it has passed 61936 which is the 60 second value. Notice that PAUSE cannot be used during this time because it also POKEs the value.

Routines such as in lines 657-659 are found in modes 2 and 3. These routines are needed to add spaces to a user input because the input has to be the same length as the answer in the array for the two to be compared.

The Variables

To facilitate user changes, the list of variables used in the program is as follows:

T$: The title of the program.

C$: The name of the user entered at the beginning.

M$: The name of the first class of items.

N$: The name of the second class of items.

L1: The length of the longest item in the first list.

L2: The length of the longest item in the second list.

A: The user menu input; also used in FOR-NEXT loops.

Z: The review speed.

TOT: The total number of items in the list.

U: Score for the drill and speed quizzes.

F1: Flag used in the utility program.

F2: Flag-1 if the list is fewer than 40 items.

D$: Generally used for user inputs.

L$: SAVE name.

P: 16437; used in POKE after PAUSE statements.

Q: 255; used in POKE after PAUSE statements.

A$(?,?): Array used for first list items; dimensioned as A$(TOT,L1).

B$(?,?): Array used for second list items; dimensioned as B$(TOT,L2).

E$(?): Array used to keep track of correctly answered items in drill mode; dimensioned as E$(TOT).

Final Observations

If you SAVE the program first without any list entered, it is ready for use with any list. Of course, after you have entered a list, the program and your list should be SAVEd together. You can have as many custom programs as you need. Changes in the program may broaden its use in your particular situation. SYNC would be interested in hearing from readers concerning their use of this program.

Listing 1.

   1 REM LIST LEARNING BASE PROG
RAM BY JAMES JOHN HOLLANDSWORTH,
[address omitted]--PH
ONE [phone number omitted]
3 REM REVISED 8-4-82
4 REM TO RUN PROGRAM TYPE
GOTO 100
5 REM TO MANIPULATE LIST TYPE
GOTO 1000
10 LET B=INT (RND*TOT)+1
12 CLS
13 PRINT "--------HIT Q FOR ME
NU---------"
14 RETURN
15 LET D$=INKEY$
16 IF D$="Q" THEN GOTO 990
17 RETURN
20 PRINT "IN THIS MODE, ";C$;"
."
21 RETURN
25 PRINT "YOU SAID IT WAS ";D$
;"."
26 RETURN
30 PRINT TAB 8;"YOU ARE CORREC
T."
31 RETURN
100 PRINT T$
104 PRINT AT 5,0;"PLEASE TYPE I
N YOUR NAME."
110 INPUT C$
115 CLS
120 PRINT "HELLO, ";C$;"."
125 PRINT "I WILL HELP YOU LEAR
N SOME ";M$;"S AND THEIR ";N$;"S
. THE MENU OF THINGS I CAN DO I
S:"
126 PRINT
130 PRINT "1. REVIEWING THE LIS
T"
131 PRINT "2. PRACTICE DRILL"
132 PRINT "3. SPEED QUIZ"
133 PRINT "4. EXIT THE PROGRAM"
134 PRINT
135 PRINT "PLEASE TYPE IN THE N
UMBER OF YOUR CHOICE, ";C$;".
"
140 INPUT A
142 IF A<>1 AND A<>2 AND A<>3 A
ND A<>4 THEN GOTO 140
145 CLS
150 GOTO A*200
200 PRINT "REVIEWING THE LIST--
-"
205 GOSUB 20
210 PRINT "I WILL DISPLAY A ";N
$;" ON THE SCREEN, PAUSE, THEN D
ISPLAY THE ";M$;". AFTER REVIEW
ING ALL ";TOT;" I WILL SWITCH TO
SHOWING THE ";M$;" FIRST. TYPE
A NUMBER FROM 0 TO 9--0 BEING A
VERY FAST REVIEW AND 9 THE SLOW
EST."
215 INPUT Z
217 IF Z<0 OR Z>9 THEN GOTO 215
220 FOR A=1 TO TOT
225 GOSUB 12
230 PRINT AT 10,8;B$(A);" ";
235 PAUSE 20+Z*10
236 POKE P,Q
240 GOSUB 15
245 PRINT A$(A)
250 PAUSE 20+Z*10
251 POKE P,Q
255 GOSUB 15
260 NEXT A
265 FOR A=1 TO TOT
270 GOSUB 12
275 PRINT AT 10,8;A$(A);" ";
280 PAUSE 20+Z*10
281 POKE P,Q
285 GOSUB 15
290 PRINT B$(A)
295 PAUSE 20+Z*10
296 POKE P,Q
300 GOSUB 15
305 NEXT A
310 GOTO 220
400 PRINT "PRACTICE DRILL---"
405 GOSUB 20
410 PRINT "I WILL GIVE YOU 15 "
;M$;"S IN SUCCESION. YOU TYPE I
N THEIR ";N$;"S. THEN I WILL GI
VE 15 ";N$;"S AND YOU TYPE IN TH
E ";M$;"S. PRESS ENTER TO START
."
412 LET U=0
415 INPUT Z$
419 IF F2 THEN GOTO 435
420 FOR A=1 TO TOT
425 LET E$(A)=CHR$ 0
430 NEXT A
435 FOR A=1 TO 15
440 GOSUB 10
445 IF E$(B)="X" THEN GOTO 440
447 PRINT AT 9,0;"TYPE IN THE "
;N$;" FOR--"
450 PRINT AT 10,8;A$(B)
460 INPUT D$
462 GOSUB 25
465 GOSUB 16
470 IF LEN D$=L2 THEN GOTO 475
472 LET D$=D$+" "
473 GOTO 470
475 IF D$=B$(B) THEN GOTO 490
477 PRINT TAB 8;"NO, IT IS ";B$
(B);"."
478 PAUSE 200
479 POKE P,Q
480 GOTO 497
490 IF NOT F2 THEN LET E$(B)="X
"
492 GOSUB 30
493 LET U=U+1
495 PAUSE 100
496 POKE P,Q
497 NEXT A
500 FOR A=1 TO 15
505 GOSUB 10
510 IF E$(B)="X" THEN GOTO 505
512 PRINT AT 9,0;"TYPE IN THE "
;M$;" FOR--"
515 PRINT AT 10,8;B$(B)
520 INPUT D$
525 GOSUB 25
527 GOSUB 16
530 IF LEN D$=L1 THEN GOTO 545
535 LET D$=D$+" "
540 GOTO 530
545 IF D$=A$(B) THEN GOTO 560
550 PRINT TAB 8;"NO, IT IS ";A$
(B);"."
553 PAUSE 240
554 POKE P,Q
555 GOTO 575
560 GOSUB 30
565 IF NOT F2 THEN LET E$(B)="X
"
570 PAUSE 120
571 POKE P,Q
572 LET U=U+1
575 NEXT A
580 CLS
585 PRINT "YOU GOT ";U;", ";C$;
"."
586 PRINT "A VERY GOOD SCORE IN
DEED."
590 PRINT "HIT ENTER TO RETURN
TO MENU."
592 INPUT D$
595 GOTO 990
600 PRINT "SPEED QUIZ---"
605 GOSUB 20
610 PRINT "I WILL GIVE YOU ";M$
;"S-TYPE IN THE ";N$;"S. AFTER 6
0 SEC. I WILL DISPLAY YOUR SCORE
. I WILL GIVE YOU 1 POINT FOR A
CORRECT ANSWER TAKE 1 POINT FOR
AN INCORRECT ANSWER AND NOT DO
ANYTHING IF YOU ONLY PRESS ENTER
. PRESS ENTER TO START."
612 LET U=0
615 INPUT D$
620 POKE P-1,0
625 POKE P,0
630 GOSUB 10
640 PRINT AT 10,8;A$(B)
645 INPUT D$
647 IF PEEK (P-1)+256*PEEK (P)<
61936 THEN GOTO 580
650 IF D$="" THEN GOTO 630
655 GOSUB 16
657 IF LEN D$=L2 THEN GOTO 660
658 LET D$=D$+" "
659 GOTO 657
660 IF D$<>B$(B) THEN LET U=U-1
665 IF D$=B$(B) THEN LET U=U+1
670 GOTO 630
800 PRINT "YOUVE DONE VERY WELL
";C$;"."
805 PAUSE 120
806 POKE P,Q
807 PRINT
810 PRINT "I HOPE YOU HAVE ENJO
YED YOURSELFAND LEARNED SOMETHIN
G."
812 PRINT
815 PAUSE 120
816 POKE P,Q
820 PRINT "******* HAVE A NICE
DAY ********"
822 PAUSE 1000
823 POKE P,Q
824 CLS
825 GOTO 100
990 CLS
995 GOTO 130
996 SAVE L$
997 GOTO 100
1000 PRINT "LIST LOADER PROGRAM"
1005 GOTO 1327
1008 LET F1=0
1009 PRINT "TYPE THE TITLE OF YO
UR LIST."
1010 INPUT T$
1011 LET P=16437
1012 LET F2=0
1013 LET Q=255
1015 CLS
1020 PRINT "TYPE THE TITLE(SINGU
LAR) OF THE 1ST CLASS OF ITEMS I
N YOUR LIST. THE 1ST CLASS SHOU
LD CONSIST OF THE LONGEST ITEMS
IN LENGTH IF POSSIBLE."
1030 INPUT M$
1035 CLS
1040 PRINT "HOW MANY CHARACTERS
ARE IN THE LONGEST ITEM IN THE
1ST CLASS?"
1050 INPUT L1
1055 CLS
1060 PRINT "TYPE THE TITLE(SINGU
LAR) OF THE 2ND CLASS."
1070 INPUT N$
1075 PRINT "HOW MANY CHARACTERS
ARE IN THE LONGEST ITEM IN THE
2ND CLASS?"
1080 INPUT L2
1085 CLS
1090 PRINT "HOW MANY ITEMS IN EA
CH CLASS OF THE LIST?"
1095 INPUT TOT
1100 CLS
1105 PRINT "TITLE-";T$
1110 PRINT "TITLE 1ST CLASS-";M$
1115 PRINT "LONGEST STRING 1ST C
LASS-";L1
1120 PRINT "TITLE 2ND CLASS-";N$
1125 PRINT "LONGEST STRING 2ND C
LASS-";L2
1130 PRINT "ITEMS IN LIST-";TOT
1135 PRINT
1140 PRINT "IS THIS INFORMATION
CORRECT-Y/N?"
1145 INPUT Z$
1150 IF Z$="N" THEN RUN 1000
1151 IF TOT<40 THEN LET F2=1
1160 DIM A$(TOT,L1)
1165 DIM B$(TOT,L2)
1170 DIM E$(TOT)
1175 CLS
1185 PRINT AT 10,0;"ENTER THE 1S
T ITEM IN THE 1ST CLASS/THEN 1
ST ITEM IN 2ND CLASSTHEN 2ND ITE
M IN 1ST CLASS, ETC."
1190 FOR A=1 TO TOT
1200 IF NOT F1 THEN GOTO 1250
1205 SCROLL
1210 PRINT M$;"--";A$(A)
1215 SCROLL
1220 PRINT N$;"--";B$(A)
1225 INPUT Z$
1230 IF Z$="" THEN GOTO 1290
1250 SCROLL
1255 PRINT M$;"--";
1260 INPUT A$(A)
1265 PRINT A$(A)
1270 SCROLL
1275 PRINT N$;"--";
1280 INPUT B$(A)
1285 PRINT B$(A)
1290 NEXT A
1292 CLS
1295 IF F1 THEN GOTO 1320
1300 PRINT AT 10,0;" WE WILL NOW
REVIEW EACH PAIR OFITEMS. WHEN
THEY COME ON THE BOTTOM OF TH
E SCREEN, HIT ENTER IF THEY ARE
CORRECT. HIT X AND THEN ENTER I
F THEY WRONG. THEN ENTER EACH O
F THEM AS YOU DID BEFORE."
1305 LET F1=1
1310 GOTO 1190
1320 PRINT "TYPE IN THE NAME YOU
WISH TO SAVE THIS PROGRAM UN
DER."
1325 INPUT L$
1326 PRINT "SAVE NAME--";L$
1327 PRINT
1328 PRINT
1330 PRINT
1335 PRINT "1. LOAD NEW LIST "
1336 PRINT "2. REVIEW/REVISE LIS
T "
1337 PRINT "3. CHANGE SAVE NAME"
1338 PRINT "4. SAVE PROGRAM"
1339 PRINT
1340 PRINT "TYPE IN THE NUMBER O
F YOUR CHOICE. IF YOU INTE
ND TO SAVE START RECORDER AS SO
ON AS YOU PRESS ENTER."
1345 INPUT A
1346 CLS
1347 IF A=4 THEN GOTO 996
1348 IF A=1 THEN RUN 1007
1349 IF A=3 THEN GOTO 1320
1350 IF A=2 THEN GOTO 1300
1355 GOTO 1330

Note: Type-in program listings on this website use ZMAKEBAS notation for graphics characters.