EasyManua.ls Logo

Commodore 128D - Page 337

Commodore 128D
427 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...
SON
SIN
SPC
SQR
—Return
sign
of
argument
X
SGN(X)
This
function
returns
the
sign,(positive,
negative
or
zero)
of
X.
The
result
is
+1
if
X
>
0,0
if
X
=
0,
and
-
1
if
X
<
0.
EXAMPLE:
PRINT
SGN(4.5);SGN(0);SGN(-2.3)
1
0
-1
—Return
sine
of
argument
SIN(X)
This
is
the
trigonometric
sine
function.
The
result
is
the
sine
of
X.
X
is
measured
in
radians.
EXAMPLE:
PRINT
SIN
(tt/3)
.866025404
—Skip
spaces
on
the
screen
SPC
(X)
This
function
is
used
in
PRINT
or
PRINT*
commands
to
control
the
formatting
of
data,
as
either
output
to
the
screen
or
output
to
a
logi
cal
file.
The
number
of
SPaGes
specified
by
X
determines
the
num
ber
of
characters
to
fill
with
spaces
across
the
screen
or
in
a
file.
The
value
of
the
argument
is
in
the
range
0
to
255.
See
also
TAB.
EXAMPLE
PRINT
"COMMODORE";SPC<3);"128"
COMMODORE
128
—Return
square
root
of
argument
SQR(X)
This
function
returns
the value
of
the
SQuare
Root
of
X,
where
X
is
a
positive
number
or
0.
The
value
of
the
argument
must
not
be
nega
tive,
or
the
BASIC
error
message
7ILLEGAL
QUANTITY
is
displayed.
EXAMPLE:
PRINT
SQR(25)
5
329
BASIC
7.0
ENCYCLOPEDIA—Basic
Functions

Table of Contents

Other manuals for Commodore 128D

Related product manuals