Commodore 16 User Manual
Download Operation & user’s manual of Commodore 16 Desktop for Free or View it Online on All-Guides.com.
ATN(X) (arclangeni)
Returns the angle
whose tangent is X.
measured
in radians.
COS(X) (cosine)
Returns the value of the cosine ol X, where X is an angle measured In
radians.
DEC (he*adecima>-string)
Returns decimal value of hexadecimal-string
(0<
nexadeclmal-
slrlng<FFFF)
EXAMPLE:
N=DEC("F4")
EXP(X)
Returns Ihe value of
the malhemaOca!
constanl
o (2.71
8281
83)
raised
lo the power of
X.
FNxx(x)
Returns
Ihe value ol Ihe user-delined lunction xx
created
In
a
DEF FNxx
statement
144
I
I
I
I
I
I
f
(
INSTB
(string 1 .
string
2
[.starting-position])
Returns position of
string 2 in string 1 ai or
after Ihe
(starting-position]
The
starting-position
defaults lo the
beginning of
string
2
If no match is
found, a
value of is returned
EXAMPLE:
PRINT
INSTR("THE CAT IN THE HAT",
"CAT")
Ihe
result is
5,
because
CAT starts at
the fifth cnaracter in
string
INT(X)
(integer)
Returns
Ihe integer
portion of
X.
with all
decimal places to the
right of
the
decimal pc-nl removed. The
result is
always tess-than or
equal to
X,
Thus, any
negative
numbers
with decimal places become
the
Integer
icss-than their current value (e.g.
INT(-4.5)--5)
If the INT
function Is to be used
lor rounding off, Ihe
form is INT(X + .5)
or INT(X
-
.5).
EXAMPLE;
X
=
INT(X-100
+
.5J/10O
Rounds to the
next highest
penny
JOY <n)
When n
-
1
Position of joystick
#1
2.. -
-
Position ofioystick #2
n
Any value
of 1
28
or more means Ihe
fire button is
also depressed.
The
direction is indicated as loPows
-
.
I «S