EasyManuals Logo
Home>Casio>Desktop>FX-795P

Casio FX-795P User Manual

Casio FX-795P
133 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #56 background imageLoading...
Page #56 background image
CHAPTER
Programming
with
BASIC
Language
The
DEFM
command
cannot
only
be
used
in
manual
operation
but
can
also
be
used
in
a
program.
For
example,
if
we
wish
to
use
array
variables
Z
(0)
to
Z
(20)
in
a
program
and
assign
a
numeric
value
J
to
Z
(J),
the
program
can
be
created
as
follows.
Example:
1@
DEFM
20°
---20
variables
are
expanded.
FOR
J=@
TO
2
30
Z(
JS
)=d
Numeric
values
are
assigned
to
the
array
variables.
4@
NEXT.
J
*When
the
DEFM
command
is
used
in
a
program,
the
number
of
variables
will
not
be
displayed
when
executed.
The
DEFM
command
is
also
used
to
display
the
current
number
of
variables.
DEFM
only
will
be
executed
in
this
instance.
om
ory
DEAM
ed
AesZi26
DEFM?
2
*When
“DEFM”
only
is
used
in
a
program,
the
number
of
variables
will
be
dis-
played
when
executing
the
program.
Notes:
1.
If
the
variables
ar
power
is
turned
0
*The
variables
will
return
to
the
standard
26
if
NEW
ALL
the
WRT
mode
or
if
changed
over
to
the
DIM
mode.
e
expanded,
that
specification
will
be
saved
even
when
the
¢.
Execute
DEEM
0
to
return
to
the
standard
26
variables.
fe}
is
operated
in
fee
Zi
26
DEEMED
BOHMer
2. If
the
number
of
bytes
used
to
expand
the
variables
is
specified
in
excess
of
the
remaining
free
area,
a
MEMORY
OVER
error
(Error
1).
will
occur
to
protect
the
stored.
programs
and
data.
98
5-3
Variables
<
Precautions
in
Using
Variables
>
1)
If
the
names
of
the
numeric
variable
and
character
variable
are
the
same,
the
same.memory
space
will
be
used.
For
this
reason,
it
will
therefore
not
be
possible
to
use
a
numeric
variable
A
and
a
character
variable
A$
at
the
same
time.
If
the
following
program
is
executed,
an
error
(Error
6)
will
occur
on
line
20
.
(See
page
68
for
details.)
10
A$=*CASIO%
Assigns
character
string
“CASIO”
to
charac-
ter
variable
A$.
20
PRINT
A...
Displays
the
content
of
numeric
variable
A.
38
END
*
Excluding
array
variables
in
the
DIM
mode.
2)
Care
should
be
taken
when
using
an
array
variable
in
the
DEFM
mode
since
it
uses
the
same
memory
space
as
some
of
the
simple
variables.
In
the
figure
shown
below,
the
variables
combined
with
equal:
signs
(=)
use
the
same
memory
space.
(Although
numeric
variables
are
shown;
these
relations
are
the
same
as
for
character
variables.)
A=A\(0)
B=
A(1)=
B(0)
C=A(2)=
B(1)=
C(0)
D=A(3)
)
Y=
A=
B=
CH=
Z=AQ)=
BM
=Ch3=
Simple
variables
Array
variables
For
example,
if
we
execute
the
following
program,
the
content
of
variable
C
will
be
10.
1@
DEFM
20
C=e@
30
A(2)=10
4@
PRINT
C
5@
END
3)
Since
variables
are
common
in
all
program
areas,
care
should
be
taken
in
|
assigning
variables
when
creating
programs
using
multiple
program
areas.
99

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Casio FX-795P and is the answer not in the manual?

Casio FX-795P Specifications

General IconGeneral
BrandCasio
ModelFX-795P
CategoryDesktop
LanguageEnglish

Related product manuals