I
I
I
1 / 4
I
1
I
I
I
f
I
I
I
I
I
INPUT
INPUT# file number, variable list
This works like INPUT, but takes the data from a previously OPENed
file or device. No prompt string is allowed. This command can only be
used In program mode.
EXAMPLE
INPUT#2, AS, C, DS
LET
(LET) variable a expression
The word LET is hardly ever used in programs, since it is not
necessary, but the statement itself is the heart of all BASIC programs.
Whenever a variable is defined or given a value. LET is always implied.
The variable name which is to get the result of a calculation is on the
left side of the equal sign, and the number or formula is on the right
side.
EXAMPLE
10 LET A = 5
20 B = 6
LET is implied (but not necessary)
in lines 20, 30 and 40.
30 C = A • B + 3
40 DS = "HELLO"
LOCATE
LOCATE x-coordinate, y-coordinate
The LOCATE command lets you put the pixel cursor (PC) anywhere on
the screen. The PC is the current location of the starting point of the
next drawing. Unlike the regular cursor. you can't see the PC. but you
can move it with the LOCATE command. For example.
LOCATE 160, 100
positions the PC in the centre of the high resolution screen. You won't
see anything until you actually draw something. You can find out
where the PC is at any time by using the RDOT(0) function to get the X-
coordinate and RDOT(1) to get the Y-coordinate. The colour source of
the dot at the PC can be found by PRINTing RDOT(2). (In all drawing
commands where a colour option is available, you may select a value
from 0 to 3, corresponding to the background, foreground, multicolour
1, or multicolour 2 as the colour source.)
MONITOR
MONITOR
This command takes you out of BASIC into the built-in machine
language monitor program The monitor
G
used to develop. debug.
and execute machine language programs more easily than from BASIC.
See the section on monitor commands for more Information. (When in
the monitor, typing an 'X' and pressing
run
gets you back to
BASIC.)
NEXT
NEXT (variable,
,variable)
124
125
Need help?
Do you have a question about the Commodore 16 and is the answer not in the manual?
Questions and answers