Radio Shack TRS-80 User Manual page 226

Micro computer system
Hide thumbs Also See for TRS-80:
Table of Contents

Advertisement

For
a
sample run
of the
program, assume
it
is
the
first
day
of the
month.
Enter
plausible
temperature and humidity
figures.
Continue running
the
program
until
you've got
a
cumu-
lative listing
for several
days.
Getting the
feel
for
data
files?
Suggestions for Further
Use
of Data
Files
1
.
Teaching/Testing. Write
a
program
that
gives
a multiple-choice
test,
for
example,
a
voca-
bulary
test.
Include ten
questions.
The
program
should
write the student's
name
and
all
ten responses
onto
a cassette
data
file.
Design the
program
so that
any
number
of students
may
take the
test
in
sequence. Include
instructions
about
when
to
use the
RECORD,
PLAY
and
STOP
keys.
Write a grader
program
that uses
the data
file
created
above
to
read each
student's
name
and
responses, grade
the
test,
and
then read
the
next
student's
test.
Be
sure to leave
time
for
the
teacher to
mark
down
the
names
and
grades
in his
or
her
little
black
book.
2.
Inventory. Write
a
program
that
sets
up
an array
in
which
you
store
the following
infor-
mation about
a
group
of
cars;
License
No.
Engine
Size
Color
Code
Body
Style
The program
should then
store
the
array
in
a
data
file.
W
7
rite
another
program which
1.
Asks
you
which
car
you're
interested
in
(you
enter the
license
number).
2.
Reads
the data
file
until
it
comes
to the
correct license
number.
3.
Prints
out
all
the
information
about
that particular
car.
(See
Chapter
21,
where
this
same
array
was
developed,)
M
224

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents