EasyManua.ls Logo

Commodore PET - Format Conventions; BASIC Commands; Clr; Cont

Commodore PET
447 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
fORMAT
CONVENTIONS
The
following
conventions are used in the
format
presentations:
UPPER
CASE
Words
in
upper case are constant and must
be
typed in
exactly
as
shown.
lower case
Words
in lower case are variable; the exact
wording
or
value
is
supplied by the programmer.
Braces indicate a choice of items; braces do not appear
in
an
actual statement.
Ellipses indicate
that
the preceding item can
be
re-
peated; ellipses do not appear in actual statements.
line number ln the format presentations, a beginning line number
is
implied for ail stored program statements.
variable Unless otherwise specified, a variable may
be
un-
subscripted
(a
simple variable) or subscripted
(an
array
element).
BASIC
COMMANDS
CLR
The Clear command,
CLR,
reinitializes ail of the PETs
"system"
pointers to
user program variables and initializes the Stack Pointer. This
is
equivalent to turn-
ing the
PET
off, then turning
it
back
on,
and loading a fresh copy of the program
into memory.
Format:
CLR
After
CLR,
ail numeric variables are assumed
to
have values of zero and ail
string variables are assumed to have null values
until
the variable
is
given a
different value by a program or immediate mode assignment.
PET
BASIC state-
ments
that
can assign values to variables are LET=,
GET,
GET#, INPUT, INPUT#,
and
READ.
CLR
may
be
given in immediate or program mode.
Example:
CLR
CONT
The Continue commando CONT, resumes program execution after a
BREAK.
A break
is
usually caused by pressing the
STOP
key in immediate mode or execut-
ing a
STOP
statement in program mode.
772

Table of Contents

Related product manuals