354 The VIC 20
User
Guide
Listed lines are reformatted as follows:
1.
?'s entered as a shorthand for
PRINT
are expanded
to
the word
PRINT. Example:
? A becomes
PRINT
A
2.
Blanks preceding the line number are eliminated. Example:
50
A=I
50
A=I
becomes
100
A=A+
1
100
A=A+
1
3.
A space
is
inserted between the line number and the rest
of
the
statement if none was entered. Example:
55A=B-2
becomes
55
A=B-2
LIST
is
always used in immediate mode. A
LIST
statement in a
program will list the program
but
then exit to immediate mode. Attempting
to continue program execution via CONT simply repeats the LIST
indefinitely.
PrInting
a
Program
Ustlng
To
print a program listing instead
of
displaying it, OPEN a printer
logical file and execute a
CMD
statement before executing the LIST
statement. Here
is
the necessary immediate mode sequence:
OPEN
4.4
Open the printer specifying logical file 4
CMD
4 Deflect display output to the printer
LIST
Print the program listing
PRINTl4
Deflect output back to the display
CLOSE
4
LOAD
The LOAD statement loads a program from an external device into
memory.
cassette
Program
Format
LOAD
[':file
name'1[,dev]
The LOAD statement loads into memory the program file specified by
file name from the cassette unit selected by device number dev.
If
no device
is
specified, device 1
is
assumed by default; cassette unit 1
is
then selected.
If
no
file
name
is
given, the next file detected
on
the selected cassette unit
is
loaded
into memory.