Since no previous program has the character 4 in it.
PGM
4
will
be
loaded.
Because of the character-by-character search for file name matches. vou have to
be
careful when giving abbreviated names. especially if your file names are long.
For example. suppose vou save three programs successively
as:
WHILE
AWAY
THE
HOURS
WHILE A
WHILE B
Vou
will
not
be
able to load the second program
with
a LOAD "WHILE
A"
com-
mand. The first program
would
always be loaded. since it contains that character
subgroup.
There
is
something else vou must bear in mind when vou make up file names.
Although the file name may have
up
to
128
characters. only the first
16
characters are displayed by the PET. If vou save
two
programs successively
as:
SWEET
SIXTEEN
TEST
1
SWEET
SIXTEEN
TEST
2
the programs are subsequently listed
as:
SWEET
SIXTEEN
TE
SWEET
SIXTEEN
TE
so
vou can't tell
which
is
which
by examining file names
as
they are displayed.
ln summary. vou
will
find it helpful to compose file names using 16 characters or
less.
and vou should keep file names about the same length.
WRITING BASIC PROGRAMS
A BASIC program consists of a group of numbered statements.
In
con-
trast to immediate mode. statements within a program are not executed un-
til
vou
"run"
the program.
In
other words. when vou type in program state-
ments. nothing happens until vou specifically initiate program execution.
When
a
statement begins
with
a line number,
PET
BASIC stores the statement rather than
executing
it
immediately.
Aline
number
is
put
on
a statement to indicate that it
is
part of a stored program.
L1NE
NUMBERS
Every program statement begins
with
a line number that must be
unique within the program and therefore uniquely identifies the statement.
76