EasyManua.ls Logo

Texas Instruments TI Programmable 57

Texas Instruments TI Programmable 57
94 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
Loading...
SUBROUTINES:
AND
To
Use
Susroutines
RIGHT
FROM
THE
KEYBOARD:
One
advantage
of
using
subroutines
in
a
program
is
that
you
can
use
any
subroutine
in
the
program
separately
from
the
program
itself.
Todo
this,
just
press
n
while
out
of
“learn’’
mode:
The
program
pointer
will
immediately
go
to
label
n
and
execute
the
subroutine.
In
this
case
the
[INV]
key
sequence
at
the
end
of
the
subroutine
will
act
just
like
an
instruction.
Notes
On
SuBROUTINES:
Using
subroutines
is
good
programming
practice!
Subroutines
let
you
organize
your
programs
easily
(and
thus
can
help
you
find
errors
if
they
exist.)
It's
also
easier
for
other
programmers
to
understand
and
use
your
programs
when
they're
in
bite-size
subroutine
"'chunks”’.
Your
calculator
is
equipped
with
two
levels
of
subroutine
capability.
This
means
that
while
you're
inside
one
subroutine,
you
can
“‘call"
or
use
another
subroutine.
You
can't
go
to
a
third
level,
however.
If
a
second
level
subroutine
tries
to
‘call’
a
third,
a
flashing
error
condition
will
be
created.
The
“subroutine
return’
memory
has
room
for
only
two
return
locations.
You
can
easily
write
any
of
your
programs
so
that
they
can
be
used
as
subroutines
in
other
programs.
(In
fact,
most
experienced
programmers
suggest
that
you
do
this.)
Naturally,
this
won't
be
practical
for
programs
that
contain
close
to
50
steps
but
it’s
a
good
procedure
to
follow
for
any
shorter
programs,
To
do
this,
just
start
the
program
with
a
label,
and
end
it
with
an
[iN]
key
sequence.
The
[INV]
key
sequence
acts
just
like
an
instruction
if
the
subroutine
return
memory
is
empty.

Related product manuals