Yale-New Haven Teachers Institute Home

Looking into the Connecticut Daily Numbers

by
Anthony P. Solli


Contents of Curriculum Unit 81.06.08:

To Guide Entry


Teaching level

For elementary school teachers, grades 4 6, and teachers, grades 7 and 8. Individual students or small groups may follow the curriculum independently. The unit may also be used as a motivational or summary part of a prealgebra or algebra course with BASIC programming. This curriculum will teach the importance of developing logical thought processes and of intelligent approaches to problemsolving techniques. One of the outstanding “side effects” of computer literacy is related to the very nature of programming. Computer programming requires that a detailed set of stepbystep instructions be given to the computer. Omission of a step, illogical order, or an incorrect step will result in either incorrect operation of the program, or in the program refusing to run to completion. A student who learns programming will learn quickly the importance and methods of organizing his thoughts and actions.

The length of time needed to teach this unit could be two or three weeks, depending on the amount of time you would spend teaching or reviewing the language of BASIC with your class.

to top


Prerequisite

Students should have at least a working knowledge of the computer language called BASIC, a quaint little language used by humans to tell computers what they are supposed to do. The word “BASIC” is an acronym for “Beginners Allpurpose Symbolic Instruction Code.” BASIC (which should always be written in capital letters) was invented by Kemeny and Kurtz at Dartmouth College in 1963.

For a beginning class in BASIC, the reader is referred to other units in this volume. In particular, the units of Joyce Bryant and Lauretta Fox.

to top


Equipment: Since many teachers have had little or no exposure to computers in general and to the TRS80 in particular, this section is designed to help you understand the system. The Radio Shack TRS80 is a compact system, made up of four components.

A keyboard unit, which looks like a typewriter, contains the actual computing circuiting, called the “central processing unit”.

A video monitor, which looks like a television screen, is specifically designed for use with the TRS 80. It differs from a standard television in two respects: It has a broader bandwidth than most “home TV’s”, a characteristic which produces sharper screen images for greater legibility of the display, and does not contain a tuner.

A cassette recorder which looks like and is a tape recorder. The recorder is a standard audio recorder which was chosen for its compatibility with the TRS80 and has been modified somewhat for this use.

The power supply powers the keyboard unit. Using a separate power supply eliminates bulk, size, and heat in the keyboard design,

What follows are computer programs that look into the Connecticut Daily Numbers.

Appendix I has a complete printout of the data deck used with all the programs in this unit.

to top


PROGRAM 0001 44 REM PRINT ALL POSSIBLE NUMBERS FROM 001 TO 999

50 FOR A=0 TO 9

60 FOR B=0 TO 9

70 FOR C=0 TO 9

80 PRINT TAB(30)”NUMBER =”A;TAB(31),B;TAB(32),C

90 NEXT C

100 NEXT B

110 NEXT A

120 END

to top


PARTIAL PRINTOUT
NUMBER = 00O
NUMBER = 001
NUMBER = 002
NUMBER = 003
NUMBER = 004
NUMBER = 00S
NUMBER = 0O¥
NUMBER = O07
NUMBER = 008
NUMBER = O09
NUMBER = 010
NUMBER = O11
NUMBER = O12
NUMBER = 013
NUMBER = O14
¥

¥

¥

NUMBER = 985
NUMBER = 986
NUMBER = 987
NUMBER = 988
NUMBER = 989
NUMBER = 99O
NUMBER = 991
NUMBER = 992
NUMBER = 993
NUMBER = 994
NUMBER = 995
NUMBER = 996
NUMBER = 997
NUMBER = 998
NUMBER = 999

to top


PROGRAM 0010 This program will produce a complete numerical rundown of all numbers that have been drawn from the Connecticut Daily Lottery beginning March 16, 1977 and ending June 30, 1981.

Note that the first number on a line is the count, the second, third, and fourth numbers make up the lottery number, and the fifth number on the line is the year given in the form of a decimal numeral to four digits.

(figure available in print form)

to top


PARTIAL PRINTOUT
111277.0316
260677.0317
350177.0318
401577.0319
504377.0321
690077.0322
700277.0323
887877.0324
970577.0325
1097477.0326
¥

¥

¥

129806781.0612
129917381.0613
130003281.0615
13019928l.0616
130286081.0617
130352881.0618
130454281.0619
130554881.062
130679981.0622
130734781.0623
130845681.0624
130971781.0625
131009581.0626
131159781.0627
13124 4881.0629
131300881.063

to top


PROGRAM 0011 The program that follows will print all digits that have come out in the hundreds column of the Connecticut Daily Lottery Numbers.

15 REM PR0GRAM TO LIST ALL HUNDRED DIGITS

20 FOR J=1 TO 1313

30 READ A,B,C,D

40 PRINT A;

80 NEXT J

1000 DATA 1,6,2,77.0316,6,0,6,77.0317,5,0,1,77.0318

1005 DATA 0,1,5,77.0319,0,4,3,77.0321,9,0,0,77.0322

1010 DATA 0,0,2,77.0323,8,7,8,77.0324,7,0,5t,77.0325

1015 DATA 9,7,4,77.0326,0,1,5,77.0328,9,7,9,77.0329

1020 DATA 3,6,0,77.033,0,2,9,77.0331,3,O,0,77.0401

1025 DATA 3,4,1,77.0402,0,0,9,77.0404,8,0,2,77.4405

1030 DATA 1,8,4,77.0406,9,4,3,77.0407,0,9,0,77.0409

1035 DATA 4,5,7,77.0411,0,0,6,77.0412,0,5,3,77.0413

1040 DATA 4,3,4,77.0414,7,8,9,77.0415,4,7,0,77.0416

1045 DATA 4,4,6,77.0418,5,6,6,77.0419,9,5,5,77.042

1050 DATA 2,1,7,77.0421,3,8,7,77.0422,8,5,4,77.0423

1055 DATA 5,1,7,77.0425,6,5,2,77.0426,9,4,0,77.0427

1060 DATA 9,3,0,77.0428,5,2,9,77.0429,5,4,4,77.043

¥

¥

¥

3150 DATA 8,7,2,81.0603,3,7,6,81.0604,0,8,0,81.0605

3155 DATA 9,0,6,81 0606,4,2,4,81.0608,6,9,5,81.0609

3160 DATA 4,9,8,8l,061,8,9,9,81.0611,0,6,7,81.0612

3165 DATA 1,7,3,81.0613,0,3,2,81.0615,9,9,2,81.0616

3170 DATA 8,6,0,81.0617,5,2,8,81.0618,5,4,2,81.0619

3175 DATA 5,4,S,81.062,7,9,9,81.0622,3,4,7,81.0623

3180 DATA 4,5,6,81.0624,7,1,7,81.0625,0,9,5,81.0626

3185 DATA 5,9,7,81.0627,4,4,8,81.0629,0,0,8,81.063

9999 END

to top


COMPLETE PRINTOUT
____(figure available in print form)

to top


PROGRAM O100 The following program will print all the digits that have come out in the tens column of the Connecticut Daily Lottery Numbers.

15 REM PROGRAM TO LIST ALL TEN DIGITS

20 FOR J=1 TO 1313

30 READ A.B.C.D

40 PRINT B;

80 NEXT J

1000 DATA 1,6,2,77.0316,6,0,6,77.0317,5,0,1,77 0318

1005 DATA 0,1,5,77.0319,0,4,3,77.0321,9,0,0,77.0322

1010 DATA 0,0,2,77,0323,8,7,8,77.0324,7,0,5,77.0325

1015 DATA 9,7,4,77.0326,0,1,5,77 0328,9,7,9,77.0329

1020 DATA 3,6,0,77 033,0,2,9,77.0331,3,0,0,77.0401

1025 DATA 3,4,1,77 0402,0,0,9,77.0404,8,0,2,77.0405

1030 DATA 1,8,4,77.0406,9,4,3,77.0407,0,9,0,77.0409

1035 DATA 4,5,7,77.0411,0,0,6,77 0412,0,5,3,77.0413

1040 DATA 4,3,4,77 0414,7,8,9,77.0415,4,7,0,77.0416

1045 DATA 4,4,6,77.0418,5,6,6,77 0419,9,5,5,77 042

1050 DATA 2,1,7,77.0421,3,8,7,77.0422,8,5,4,77.0423

1055 DATA 5,1,7,77 0425,6,5,2,77.0426,9,4,0,77.0427

1060 DATA 9,3,0,77.0428,5,2,9,77 0429,5,4,4,77.043

¥

¥

¥

3185 DATA 5,9,7,81.0627,4,4,8,81.0629,0,0,8,81.063

9999 END

to top


COMPLETE PRINTOUT
600140070717
620400849505
387465185154
324073290838
613055830916
179903320814
360859218452
512117932974
203287605354
739485141230
295937516188
147440809587
4679468.95683
9707980.71576
196946676371
73440387 3210
559179090839
13896531 7802
65491634 0004
26043149 4322
25576905 3442
30395240 5806
52805900 0917
92753461 5960
13051734 4381
32733872 8070
23596780 9986
04296332 4132
07978739 4835
96995436 6735
51754730 3898
51680833 6592
18871896 6076
95422587 3823
08792193 1405
94139059 4109
67003623 2630
89583931 7316
65527959 4303
71150701 3677
40904220 3080
09476354 3511
787597699838
875214816263
396862036352
754287799364
441375656283
754912509773
638298260357
649796229434
858256659731
044483549321
440316510049
991942373378
755652605359
263508082423
658228438650
352170862077
951369000716
¥905¥0875041
593309700471
789397&3¥080
532087¥7¥155
035¥77234004
871023793228
8920757^42731
3118539¥1¥2
¥¥4719270441
a5702920¥81.3
4¥2¥20081700
2a9¥,702¥¥27
9a1032¥¥4
9¥33589¥¥3
2¥9238¥¥7¥1
752138¥52
27992a¥73a48
221193803¥¥
3¥¥593¥¥3
1308402¥¥
0¥3¥019¥77¥3
739¥7350¥113
3270e2¥5¥7
05975¥23¥210
3¥15¥9772550
30737859135
78¥90723233
7853415899
2117¥2¥74952
7¥0289972592
0¥5¥3991¥07¥
¥3310¥55903¥3
a10s85010079
¥3¥¥1¥8¥282
038943¥28721
¥¥¥1101¥0349
1993¥7¥05012
2¥0559984938
¥38¥97¥535¥10
3940¥894.0313
¥87405733¥¥5
1¥e2,5028¥703
1915905012
75¥87194238
77_433351323
8283¥87
1¥544¥09817¥
105¥70¥94973
¥84_237780299
9¥739¥244945
1 9 9 4 0

to top


PROGRAM 0101 This next program will print all the digits that have come out in the units column of the Connecticut Daily Lottery Numbers.

15 REM PROGRAM TO LIST ALL UNIT DIGITS

20 FOR J=1 TO 1313

READ A,B,C,D

40 PRINT C;

____80 NEXT J

1000 DATA 1,6,2,77.0316,6,O,6,77.0317,5,O,1,77.0318

1005 DATA 0,1,5,77.0319,O,4,3,77.0321,9,O,O,77.0322

1010 DATA 0,O,2,77.0323,8,7,8,77.0324,7,0,5,77 0325

1015 DATA 9,7,4,77.0326,0,1,5,77.0328,9,7,9,77.0329

1020 DATA 3,6,0,77.033,0,2,9,77.0331,3,O,O,77 0401

1025 DATA 3,4,1,77.0402,0,O,9,77.0404,8,O,2,77.0405

1030 DATA 1,8,4,77.0406,9,4,3,77.0407,O,9,O,77 0409

1035 DATA 4,5,7,77.0411,O,O,6,77.0412,0,5,3,77.0413

3150 DATA 8,7,2,81.0603,3,7,6,81.0604,0,8,0,8l.0605

3155 DATA 9,0,6,81,0606,4,2,4,81.0608,6,9,5,81.0609

3160 DATA 4,9,8,81.061,8,9,9,81.0611,0,6,7,81.0612

3165 DATA 1,7,3,81.0613,0,3,2,81,0615,9,9,2,81,0616

3170 DATA 8,6,0,81.0617,5,2,8,81.0618,5,4,2,81.0619

3175 DATA 5,4,8,81.062,7,9,9,81.0622,3,4,7,81.0623

3180 DATA 4,5,6,81.0624,7,1,7,81.0625,0,9,5,81.0626

3185 DATA 5,9,7,81.0627,4,4,8,81.0629,0,0,8,81.063

9999 END

to top


COMPLETE PRINTOUT
Z¥1¥302¥¥459
0901924307¥3
490&¥¥774720
09422¥142003
01053¥¥0¥¥47
570¥0¥320553
833995¥8¥750
93294737384
033¥¥943¥302
429293007918
753¥43908707.
1_.747e9¥1814¥
9101209804&0
5231551234e2
72¥0974¥2380
S032270¥3003
488¥8974¥1 ¥ 83
09002010¥4
23882704111
22¥¥90042349
?3. 8805804144
?8¥08¥53¥994
823¥ .153000
0¥39.8e41587
2821¥ 3¥.08299
11282. 0¥02014
¥13815? 2¥448
Z38. 7891¥3510
0?25011¥8&38
0031892559. 2
_.744875t7901
919152112752
Z533 .?109 ‘ 0125
7203¥82979,, 0
9¥80458¥53
4¥4748S ^04988
*11??4555008
1¥439779198¥
7¥¥8¥2075980
230 75915¥5
¥¥7379329¥3
0110155¥20 .7.
4¥O¥¥S201
..¥03¥02¥t
796072¥¥13
:S¥02¥1¥3¥2
4,70a0212Ja0;.
7.4¥2¥2¥043¥t
2490711?9¥02
:S44527:’2aa84
432?¥?Ja0a9
043S2¥¥¥23a
¥8?¥SS13a¥¥3
448¥830303¥O
‘4¥11¥7¥1¥a4
S3¥¥¥10‘5?4
O711a2420770
43Sae37¥334
O03?¥a¥7¥2S
5¥¥a¥21a300
O¥32¥?1S2132
¥890a??92S¥2
0791¥¥4¥09
17704tS¥?2¥e
O¥5¥051147¥1
20¥¥1¥¥1¥O
4¥S9140438
11a279¥¥.¥383
.¥3¥¥99¥O¥7
1¥1408¥34¥7¥
¥342790¥¥490
?¥92S3432¥9
¥047¥¥93S3a7
990¥S072749
2¥14¥OO¥2815
¥4¥87¥930903
955o2¥¥722
174¥07583714
72520454145
349823319¥49
¥9S387344875
O44313181391
8¥8e33845807
a4 33¥91¥e45
12¥015¥82¥3a
O08247438075
505159¥21858
122549¥41312
98544473¥.5¥9
17¥¥444O¥89
3240t2131944
t708¥4070¥990 2
05413¥¥¥&281
95¥904233019
280¥O0233081
2033433775 27
73743018 2245
35¥72¥. 20¥3253
¥2¥089413a08
21538O182157
728¥91O.7¥98
¥¥5393¥15932
?9_5837798379
¥07349043505
¥¥O020¥¥774
01381798¥78
934 _70211¥.029
9702S2¥O¥458
97322082a97
7¥788.,
Student activities:

Have students develop programs:

To find just the odd numbers

To find just the even numbers

To find all the ones

To find all the twos, etc.

To add, subtract, multiply, or divide pairs of numbers, etc.

to top


PROGRAM 0110 4 REM FREQUENCY DISTRIBUTION PROGRAM

6 REM HUNDRED COLUMN DIGITS

8 LET A0=0

10 LET A1=0

12 LET A2=0

14 LET A3=0

16 LET A4=0

18 LET A5=0

20 LET A6=0

22 LET A7=0

24 LET A8=0

26 LET A9=0

28 FOR J=1 TO 1313

30 READ A,B,C,D

32 IF A=0 THEN 52

34 IF A=1 THEN 56

36 IF A=2 THEN 60

38 IF A=3 THEN 64

40 IF A=4 THEN 68

42 IF A=5 THEN 72

44 IF A=6 THEN 76

46 IF A=7 THEN 80

48 IF A=8 THEN 84

5O IF A=9 THEN 88

52 LET A0=A0+1

54 GOTO 90

56 LET A1=A1+1

58 GOTO 90

60 LET A2=A2+1

62 GOTO 90

64 LET A3=A3+1

66 GOTO 90

68 LET A4=A4+1

70 GOTO 90

72 LET A5=A5+1

74 GOTO 90

76 LET A6=A6+1

78 GOTO 90

80 LET A7=A7+1

82 GOTO 90

84 LET A8=A8+1

86 GOTO 90

88 LET A9=A9+1

90 NEXT J

92 LET T=A0+A1+A2+A3+A4+A5+A6+A7+A8+A9

94 FOR J0=1 TO A0

96 PRINT “0”;

98 NEXT J0

100 PRINT

102 PRINT

104 FOR J1=1 TO A1

106 PRINT “l”;

108 NEXT J1

110 PRINT

112 PRINT

114 FOR J2=1 TO A2

116 PRINT “2”;

118 NEXT J2.

120 PRINT

122 PRINT

124 FOR J3=1 TO A3

126 PRINT “3”;

128 NEXT J3

130 PRINT

132 PRINT

134 FOR J4=1 TO A4

136 PRINT “4”;

138 NEXT J4

140 PRINT

142 PRINT

144 FOR J5=1 TO A5

146 PRINT “5”;

148 NEXT J5

150 PRINT

152 PRINT

154 FOR J6=1 TO A6

155 PRINT “6”;

158 NEXT J6

160 PRINT

162 PRINT

164 FOR J7=1 TO A7

166 PRINT “7”;

168 NEXT J7

170 PRINT

172 PRINT

174 FOR J8=1 TO A8

176 PRINT “8”;

178 NEXT J8

180 PRINT

182 PRINT

184 FOR J9=1 TO A9

186 PRINT .”9”

188 NEXT J9

190 PRINT

192 PRINT

194 PRINT

196 PRINT

198 PRINT

200 PRINT “NUMBER OF ZERO DIGITS=”;A0

202 PRINT “NUMBER OF ONE DIGITS=”;A1

204 PRINT “NUMBER OF TWO DIGITS=”;A2

206 PRINT “NUMBER OF THREE DIGITS=”;A3

208 PRINT “NUMBER OF FOUR DIGITS=”;A4

210 PRINT “NUMBER OF FIVE DIGITS=”;A5

212 PRINT “NUMBER OF SIX DlGITS=”;A6

214 PRINT “NUMBER OF SEVEN DIGITS=”;A7

216 PRINT “NUMBER OF EIGHT DIGITS=”;A8

218 PRINT “NUMBER OF NINE DIGITS=”;A9

220 PRINT “TOTAL=”;T

1000 DATA 1,6,2,77.0316,6,0,6,77.0317,5,0,1,77.0318

1005 DATA 0,1,5,77.0319,0,4,3,77.0321,9,0,0,77.0322

1010 DATA 0,0,2,77.0323,8,7,8,77.0324,7,0,5,77.0325

1015 DATA 9,7,4,77.0326,0,1,5,77.0328,9,7,9,77.0329

1020 DATA 3,6,0,77.033,0,2,9,77.0331,3,0¥0,77.0401

1025 DATA 3,4,1,77.0402,0,0,9,77.0404,8,0,2,77.0405

1030 DATA 1,8,4,77.0406,9,4,3,77.0407¥0,9,0,77.0409

1035 DATA 4,5,7,77.0411,0,0,6,77.0412,0,5,3,77 0413

1040 DATA 4,3,4,77.0414,7,8,9,77.0415,4,7,0,77.0416

1045 DATA 4,4,6,77.0418,5,6,6,77.0419,9,5,5,77.042

1050 DATA 2,1,7,77.0421,3,8,7,77 0422,8,5,4,77.0423

1055 DATA 5,1,7,77.0425,6,5,2,77.0426,9,4,0,77.0427

1060 DATA 9,3,0,77.0428,5,2,9,77 0429,5,4,4,77.043

¥

¥

¥

3150 DATA 8,7,2,81.0603,3,7,6,81.0604,0,8,0,81.0605

3155 DATA 9,0,6,81.0606,4,2,4,81.0608,6,9,5,81.0609

3160 DATA 4,9,8,81.061,8,9,9,81.0611,0,6,7,81.0612

3165 DATA 1,7,3,81.0613,0,3,2,81.0615,9,9,2,81.0616

3170 DATA 8,6,0,81.0617,5,2,8,81.0618,5,4,2,81.0619

3175 DATA 5,4,8,81.062,7,9,9,81.0622,3,4,7,81.0623

3180 DATA 4,5,6,81.0624,7,1,7,81.0625,0,9,5,81.0626

3185 DATA 5,9,7,81.0627,4,4,8,81.0629,0,0,8,81.063

9999 END

to top


COMPLETE PRINTOUT
(figure available in print form)
NUMBER OF ZERO DIGITS= 146

NUMBER OF ONE DIGITS= 132

NUMBER OF TWO DIGITS= 134

NUMBER OF THREE DIGITS= 117

NUMBER OF FOUR DIGITS= 122

NUMBER OF FIVE DIGITS= 153

NUMBER OF SIX DIGITS= 118

NUMBER OF SEVEN DIGITS= 131

NUMBER OF EIGHT DIGITS= 129

NUMBER OF NINE DIGITS= 131

TOTAL= 1313

to top


PROGRAM 0111 4 REM FREQUENCY DISTRIBUTION PROGRAM

6 REM TEN COLUMN DIGITS

8 LET B0=0

10 LET B1=0

12 LET B2=0

14 LET B3=0

16 LET B4=0

18 LET B5=0

20 LET B6=0

22 LET B7=0

24 LET B8=0

26 LET B9=0

28 FOR J=1 TO 1313

30 READ A,B,C,D

32 IF B=0 THEN 52

34 IF B=1 THEN 56

36 IF B=2 THEN 60

38 IF B=3 THEN 64

40 IF B=4 THEN 68

42 IF B=5 THEN 72

44 IF B=6 THEN 76

46 IF B=7 THEN 80

48 IF B=8 THEN 84

50 IF B=9 THEN 88

52 LET B0=B0+1

54 GOTO 90

56 LET B1=B1+1

58 GOTO 90

60 LET B2=B2+1

62 GOTO 90

64 LET B3=B3+1

66 GOTO 90

68 LET B4=B4+1

70 GOTO 90

72 LET B5=B5+1

74 GOTO 90

76 LET B6=B6+1

78 GOTO 90

80 LET B7=B7+1

82 GOTO 90

84 LET B8=B8+1

86 GOTO 90

88 LET B9=B9+1

90 NEXT J

92 LET T=B0+B1+B2+B3+B4+B5+B6+B7+B8+B9

94 FOR J0=1 TO B0

96 PRINT “0”;

98 NEXT J0

100 PRINT

102 PRINT

104 FOR J1=1 TO B1

106 PRINT “1”;

108 NEXT J1

110 PRINT

112 PRINT

114 FOR J2=1 TO B2

116 PRINT “2”;

118 NEXT J2

120 PRINT

122 PRINT

124 FOR J3=1 TO B3

126 PRINT “3”;

128 NEXT J3

130 PRINT

132 PRINT

134 FOR J4=1 TO B4

136 PRINT “4”;

138 NEXT J4

140 PRINT

142 PRINT

144 FOR J5=1 TO B5

146 PRINT “5”;

148 NEXT J5

150 PRINT

152 PRINT

154 FOR J6=1 TO B6

156 PRINT “6”;

158 NEXT J6

160 PRINT

162 PRINT

164 FOR J7=1 TO B7

166 PRINT “7”;

168 NEXT J7

170 PRINT

172 PRINT

174 FOR J8=1 TO B8

176 PRINT “8”;

178 NEXT J8

180 PRINT

182 PRINT

184 FOR J9=1 TO B9

186 PRINT “9”;

188 NEXT J9

190 PRINT

192 PRINT

194 PRINT

196 PRINT

198 PRINT

200 PRINT “NUMBER OF ZERO DIGITS=”;B0

202 PRINT “NUMBER OF ONE DIGITS=”;B1

204 PRINT “NUMBER OF TWO DIGITS=”;B2

206 PRINT “NUMBER OF THREE DIGITS=”;B3

208 PRINT “NUMBER OF FOUR DIGITS=”;B4

210 PRINT “NUMBER OF FIVE DIGITS=”;B5

212 PRINT “NUMBER OF SIX DIGITS=”;B6

214 PRINT “NUMBER OF SEVEN DIGITS=”;B7

216 PRINT “NUMBER OF EIGHT DIGITS=”;B8

218 PRINT “NUMBER OF NINE DIGITS=”;B9

220 PRINT “TOTAL=”;T

1000 DATA 1,6,2,77.0316,6,0,6,77.0317,5,0,1,77.0318

1005 DATA 0,1,5,77.0319 0,4,3,77.0321,9,0, 0,77.0322

1010 DATA 0,0,2,77.0323,8,7,8,77.0324,7,0,5,77.0325

1015 DATA 9,7,4,77.0326,0,1,5,77.0328,9,7,9,77.0329

1020 DATA 3,6,0,77.033,0,2,9,77.0331,3,0,0,77.0401

1025 DATA 3,4,1,77.0402,0,0,9,77.0404,8,0,2,77.0405

3150 DATA 8,7,2,81.0603,3,7,6,81.0604,0,8,0,81.0605

3155 DATA 9,0,6,81.0606,4,2,4,81.0608,6,9,5,81.0609

3160 DATA 4,9,8,81.061,8,9,9,81.0611,0,6,7,81.0612

3165 DATA 1,7,3,81.0613,0,3,2,81.0615,9,9,2,81.0616

3170 DATA 8,6,0,81.0617,5,2,8,81.0618,5,4,2,81.0619

3175 DATA 5,4,8,81.062,7,9,9,81.0622,3,4,7,81.0623

3180 DATA 4,5,6,81.0624,7,1,7,81.0625,0,9,5,81.0626

3185 DATA 5,9,7,81.0627,4,4,8,81.0629,0,0,8,81.063

9999 END

to top


COMPLETE PRINTOUT
(figure available in print form)
NUMBER OF ZERO DIGITS= 146

NUMBER OF ONE DIGITS= 114

NUMBER OF TWO DIGITS= 115

NUMBER OF THREE DIGITS= 162

NUMBER OF FOUR DIGITS= 133

NUMBER OF FIVE DIGITS= 135

NUMBER OF SIX DIGITS= 122

NUMBER OF SEVEN DIGITS= 132

NUMBER OF EIGHT DIGITS= 115

NUMBER OF NINE DIGITS= 139

TOTAL= 1313

to top


PROGRAM 1000 4 REM FREQUENCY DISTRIBUTION PROGRAM

6 REM UNIT COLUMN DIGITS

8 LET C0=0

10 LET C1=0

12 LET C2=0

14 LET C3=0

16 LET C4=0

18 LET C5=0

20 LET C6=0

22 LET C7=0

24 LET C8=0

26 LET C9=0

28 FOR J=1 TO 1313

30 READ A,B,C,D

32 IF C=0 THEN 52

34 IF C=1 THEN 56

36 IF C=2 THEN 60

38 IF C=3 THEN 64

40 IF C=4 THEN 68

42 IF C=5 THEN 72

44 IF C=6 THEN 76

46 IF C=7 THEN 80

48 IF C=8 THEN 84

5O IF C=9 THEN 88

52 LET C0=C0+1

54 GOTO 90

56 LET C1=C1+1

58 GOTO 90

60 LET C2=C2+1

62 GOTO 90

64 LET C3=C3+1

66 GOTO 90

68 LET C4=C4+1

70 GOTO 90

72 LET C5=C5+1

74 GOTO 90

76 LET C6=C6+1

78 GOTO 90

80 LET C7=C7+1

82 GOTO 90

84 LET C8=C8+1

86 GOTO 90

88 LET C9=C9+1

90 NEXT J

92 LET T=C0+C1+C2+C3+C4+C5+C6+C7+C8+C9

94 FOR J0=1 TO C0

96 PRINT “O”;

98 NEXT J0

100 PRINT

102 PRINT

104 FOR J1=1 TO C1

106 PRINT “l”;

108 NEXT J1

110 PRINT

112 PRINT

114 FOR J2=1 TO C2

116 PRINT “2”;

118 NEXT J2

120 PRINT

122 PRINT

124 FOR J3=1 TO C3

126 PRINT “3”;

128 NEXT J3

130 PRINT

132 PRINT

134 FOR J4=1 TO C4

136 PRINT “4”;

138 NEXT J4

140 PRINT

142 PRINT

144 FOR J5=1 TO C5

146 PRINT “5”;

148 NEXT J5

150 PRINT

152 PRINT

154 FOR J6=1 TO C6

156 PRINT “6”;

158 NEXT J6

160 PRINT

162 PRINT

164 FOR J7=1 TO C7

166 PRINT “7”;

168 NEXT J7

170 PRINT

172 PRINT

174 FOR J8=1 TO C8

176 PRINT “8”;

178 NEXT J8

180 PRINT

182 PRINT

184 FOR J9=1 TO C9

186 PRINT “9”;

188 NEXT J9

190 PRINT

192 PRINT

194 PRINT

196 PRINT

198 PRINT

200 PRINT “NUMBER OF ZERO DIGITS=”;C0

202 PRINT “NUMBER OF ONE DIGITS=”;C1

204 PRINT “NUMBER OF TWO DIGITS=”;C2

206 PRINT “NUMBER OF THREE DIGITS=”;C3

208 PRINT “NUMBER OF FOUR DIGITS=”;C4

210 PRINT “NUMBER OF FIVE DIGITS=”;C5.

212 PRINT “NUMBER OF SIX DIGITS=”;C6

214 PRINT “NUMBER OF SEVEN DIGIT=”;C7

216 PRINT “NUMBER OF EIGHT DIGIT=”;C8

218 PRINT “NUMBER OF NINE DIGIT=”;C9

220 PRINT “TOTAL=4”;T

1000 DATA 1,6,2,77.0316,6,0,6,77.0317,5,0,1,77.0318

1005 DATA 0,1,5,77.0319,0,4,3,77.0321,9,0,0,77.0322
1010DATA 0,0,2,77.0323,8,7,8,77.0324,7,0,5,77.0325
¥

¥

¥

3185 DATA 5,9,7,81.0627,4,4,8,81.0629,0,0,8,81.063

9999 END

to top


COMPLETE PRINTOUT
(figure available in print form)
NUMBER OF ZERO DIGITS= 164

NUMBER OF ONE DIGITS= 121

NUMBER OF TWO DIGITS= 122

NUMBER OF THREE DIGITS= 141

NUMBER OF FOUR DIGITS= 126

NUMBER OF FIVE DIGITS= 127

NUMBER OF SIX DIGITS= 133

NUMBER OF SEVEN DIGIT= 118

NUMBER OF EIGHT DIGIT= 142

NUMBER OF NINE DlGIT= 119

TOTAL= 1313

The following was done on a HewlettPackard 7210A digital xy plotter.

to top


PROGRAM 1001 5 REM PROGRAM TO PLOT HUNDRED DIGITS TO TEN DIGITS

6 REM X=HUNDRED DIGIT TIMES 1000

7 REM Y=TEN DIGIT TIMES 1000

10 CALL (50,1)

20 DIM U[10,200]

30 CALL (3,U[1,1],4000)

40 FOR J=1 TO 100

5O READ A,B,C,D

55 LET X=A*1000

81 LET Y=B*1000

90 LET P=0

95 CALL (1,P,1,X,Y)

100 CALL (2,200,0,0,200)

111 PRINT “0”

120 PRINT TAB(5);”X=”;X;TAB(5);”Y=”;Y;A;B;C;D

130 NEXT J

1000 DATA 1,6,2,77.0316,6,0,6,77.0317,5,0,1,77.0318

1005 DATA 0,1,5,77.0319,0,4,3,77.0321,9,0,0,77.0322

1010 DATA 0,0,2,77.0323,8,7,8,77.0324,7,0,5,77.0325

¥

¥

¥

3150 DATA 8,7,2,81.0603,3,7,6,81.0604,0,8,0,81.0605

3155 DATA 9,0,6,81.0606,4,2,4,8l,0608,6,9,5,81.0609

3160 DATA 4,9,8,8l,061,8,9,9,81.0611,0,6,7,81.0612

3165 DATA 1,7,3,81.0613,0,3,2,81.0615,9,9,2,81.0616

3170 DATA 8,6,0,81.0617,5,2,8,81.0618,5,4,2,81.0619

3175 DATA 5,4,8,81.062,7,9,9,81.0622,3,4,7,81.0623

3180 DATA 4,5,6,81.0624,7,1,7,81.0625,0,9,5,81.0626

3185 DATA 5,9,7,81.0627,4,4,8,81.0629,0,0,8,81.063

9999 END

For an understanding of the CALL statements in BASIC, the reader is referred to the Hewlett Packard guide to 2100 series mini computers.

to top


PARTIAL PRINTOUT
(figure available in print form)

to top


PROGRAM 1010 5 REM PROGRAM TO PLOT NUMBER TO RANDOM NUMBER

6 REM X = NUMBER TIMES 1000

7 REM Y = RANDOM NUMBER

10 CALL (50,1)

20 DIM U[10,200]

30 CALL (3.U[1,1],4000)

40 FOR J=1 TO 242

50 READ A,B,C,D

55 LET Y=RND(1)*9999

81 LET X=(A*1000)+(B*100)+(C*10)

90 LET P=0

95 CALL (1,P,1,X,Y)

100 CALL (2,200,0,0,200)

111 PRINT “0”

120 PRINT TAB(5);”X”;X;TAB(5);”Y=”;Y;A;B;C;D

130 NEXT J

1000 DATA l,6,2,77.0316,6,0,6,77.0317,5,0,1,77.0318

1005 DATA 0,1,5,77.0319,0,4,3,77.0321,9,0,0,77.0322

1010 DATA 0,0,2,77.0323,8,7,8,77.0324,7,0,5,77.0325

1015 DATA 9,7,4,77.0324,0,1,5,77.0328,9,7,9,77.0329

1020 DATA 3,6,0,77.033,0,2,9,77.0331,3,0,0,77.0401

1025 DATA 3,4,1,77.0402,0,0,9,77.0404,8,0,2,77.0405

1030 DATA 1,8,4,77.0406,9,4,3,77.0407,0,9,0,77.0409

1035 DATA 4,5,7,77.0411,0,0,6,77.0412,0,5,3,77.0413

1040 DATA 4,3,4,77.0414,7,8,9,77.0415,4,7,0,77.0416

1045 DATA 4,4,6,77.0418,5,6,6,77.0419,9,5,5,77.042

1050 DATA 2,1,7,77.0421,3,8,7,77.0422,8,5,4,77.0423

1055 DATA 5,1,7,77.0425,6,5,2,77.0426,9,4,0,77.0427

1060 DATA 9,3,0,77.0428,5,2,9,77.0429,5,4,4,77.043

¥

¥

¥

3150 DATA 8,7,2,81.0603,3,7,6,81.0604,0,8,0,81.0605

3155 DATA 9,0,6,81.0606,4,2,4,81.0608,6,9,5,81.0609

3160 DATA 4,9,8,81.061,8,9,9,81.0611,0,6,7,81.0612

3165 DATA 1,7,3,81.0613,0,3,2,81.0615,9,9,2,81.0616

3170 DATA 8,6,0,81.0617,5,2,8,81.0618,5,4,2,81.0619

3175 DATA 5,4,8,81.062,7,9,9,81.0622,3,4,7,81.0623

3180 DATA 4,5,6,81.0624,7,1,7,81.0625,0,9,5,81.0626

3185 DATA 5,9,7,81.0627,4,4,8,81.0629,0,0,8,81.063

9999 END

to top


PARTIAL PRINTOUT
(fiure available in print form)
Student activities:

Have students plot:

Hundred digits to unit digits

Ten digits to unit digits

Unit digits to a random series

Ten digits to a random series

Hundred digits to a random series, etc.

A complete printout of all the programs, and punch tape of the data deck is on file at the Teacher’s Institute Office.

to top


STUDENTS’ ANNOTATED BIBLIOGRAPHY Ball, Marion J., What is a Computer?, Houghton Mifflin, Boston, 1972. Grades 4-6.

Ball, Marion J. and Sylvia Charp, Be a Computer Literate, Creative Computing Press, Morristown, New Jersey, 1977. Grades 7-8.

Corbett, Scott, Home Computers’ A Simple and Informative Guide, illustrated with photographs by Jane Corbett. AtlanticLittle, Brown, 1980, paper ea., pp. 11s. Grades 5-8. (An introduction to various small computers appropriate for home use. The child learns how prevalent the computer already is, what machines are available, how to learn the necessary language to instruct the computer, how to have fun playing with it, and how to put it to work for the family. Glossary and index.)

McQuigg, James D. and Alta M. Harness, Flowcharting, Houghton Mifflin, Boston, 1977. Grades 7-8.

Spencer, Donald D., Accent on BASIC, Camelot Publishing Company, Ormond Beach, Florida, 1977. (A text and workbook.) Grades 9-12.

Spencer, Donald D., Computer Awareness Coloring Book, Camelot Publishing Company, Ormond Beach, Florida, 1978. Grades K-3.

Spencer, Donald D., Fun with Computers and BASIC, Camelot Publishing Company, Ormond Beach, Florida, 1977. Grades 7-8.

Spencer, Donald D., What Computers Can Do, Camelot Publishing Company, Ormond Beach, Florida, 1977. Grades 7-8.

to top


TEACHERS’ ANNOTATED BIBLIOGRAPHY Ahl, David H., BASIC Computer Games, Microcomputer Creative Computing Press, Morristown, New Jersey, 1978. (An excellent source for programs. )

Ahl, David H., The Best of Creative computing. Vols. I and II, Creative Computing Press, Morristown, New Jersey, 1978. (A good source for articles and other background material.)

John G. and Thomas E. Kurtz, BASIC Programming, John Wiley and Sons, New York, 1971. (Written by the men who developed the programming language BASIC.)

Nelson, Theodor, The Home Computer Revolution, The Distributors, 702 S. Michigan, South Bend, Indiana 46618, 1977. (A lively overview of microcomputers in general.)

Radio Shack Reference Books for TRS 80

BASIC Computer Games

(84 games for solo and group play, 192 pages.)

BASIC Computer Language (Includes both programmed instruction and user programs, 232 pages,)

BASIC Computer Programming (Introduction to computers, writing programs,-156 pages.)

Beginning Computers (For the novice. Subtitles, diagrams, photos 49 pages.)

Getting Started with BASIC (Exciting introductory book covers all aspects of Level II and Model III BASIC.)

Level II Programming

Examples of Level II BASIC routines TRS80 Model I, 351 pages.)

Programming Techniques for Level II (Supplement to Level II Programming. Common BASIC operations, 142 pages.)

The BASIC Cookbook (Teaches BASIC so you can program a microcomputer, 116 pages.)

TRS80 Applications Sourcebook

Radio Shack compiled a listing of TRS80 applications for sale by a variety of vendors. Each listing includes a description, hardware required, prices and how you can order direct from the vendor.)

TRS80 Assembly/Language Programming (Computer hardware, software, microcomputers, 304 pages.)

TRS80 Graphics (How to create graphic displays with the TRS80. From line drawings to geometrics to moving figure animation, 142 pages.)

TRS80 Programs (32 fullydocumented programs readytorun on a TRS-80. Suggested program changes, also, 267 pages.)

Understanding Digital Electronics (Explains digital electronic devices, circuits and systems, 240 pages.)

Understanding Microprocessors Learn what microprocessors are and how they can be used, 296 pages.)

Victory by Computer, DC Comics Incorporated, 1981.

(A comic book starring THE TRS80 COMPUTER WHIZ KIDS and comic book favorites SUPERMAN and SUPERGIRL in an exciting introduction to micro computers. Free copies for classroom use, at participating Radio Shack Stores,)

Rice, Jean, My Friend the Computer, T. S. Denison and Company, Minneapolis, 1976. (Has outstanding manual.)

Ryan, Thomas J., The Adolescence of P1, MacMillan. New York, 1977, (A well written novel about a computer program that gets away! Good for discussion in class.)

Spencer, Donald D., BASIC, A Unit for Secondary Schools, Camelot Publishing Company, Ormond Beach, Florida, 1977, To be used in teaching programming as a unit within another course, such as algebra, chemistry, etc.)

Spencer, Donald D., Microcomputers at a Glance, Camelot Publishing Company, Ormond Beach, Florida, 1977. (A dictionary of computer terms.)

Spencer, Donald D., Using BASIC in the Classroom, Camelot Publishing Company, Ormond Beach, Florida, 1978. (An introduction to computers for teachers.)

to top


MAGAZINES Creative Computing, P. O. Box 789M, Morristown, New Jersey 07960

Recreational Computing, 1263 El Camino Real, Box E, Menlo Park, California 94025

to top


AUDIO VISUAL MATERIAL Billings, Karen and David Moursund, Are You Computer Literate? The Math Learning Center, 325-13th Street, N.E., Room 302, Salem, Oregon 97301, 1978. (A list of films.)

Spencer, Donald D., Computers for Kids, Camelot Publishing Company, Ormond Beach, Florida, 1979. (An AV kit with 60 slides, a cassette, and teachers manual.)

to top


Appendix I A printout of the data deck used with all programs in this unit.

(figure available in print form)

to top

Contents of 1981 Volume VI | Directory of Volumes | Index | Yale-New Haven Teachers Institute

© 2014 by the Yale-New Haven Teachers Institute
Terms of Use Contact YNHTI