EasyManuals Logo

HP HP-16C User Manual

HP HP-16C
140 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 #92 background imageLoading...
Page #92 background image
90
Section
9:
Program
Branching
and
Controls
Loop
Control
with
Counters:
and
The
(decrement
and
skip
next
line
if
counter
equals
zero)
and
(increment
and
skip
if
zero)
functions
can
control
loop
execution
by
referencing
and
adjusting
(incrementing/decre-
menting)
a
counter
value
in
the
Index
register.
Then,
when
that
counter
value
reaches
zero,
program
execution
skips
one
line.
Each
time
one
of
these
functions
is
encountered
in
a
running
program,
the
given
counter
value
in
the
Index
register
is
either
decremented
([DSZ])
or
incremented
([1SZ])
by
one.
If
the
resulting
value
equals
zero,
the
next
instruction
is
skipped.
This
allows
exit
from
a
loop
if
the
skipped
line
was
a
branch
into
a
loop.
Conditional
Branch
with
or
False
(R;
#
0)
True
(R}
=0)
>
EBUA
|
\
instruction
(9052
o
|
|
continue
loop
L_.y
A
exit
loop
instruction
l__J
“Skip
if
True”
The
value
in
R}
is
interpreted
according
to
the
current
complement
mode.
It
can
be
positive
or
negative,
in
integer
or
floating-point
format.
The
instructions
and
do
not
affect
the
status
of
the
carry
and
out-of-range
flags.
Example
A
“checksum”
routine
can
be
used
to test
the
integrity
of
stored
data
values.
Using
you
can
determine
the
sum
of
a
bit
pattern
and
then
compare
that
sum
to
the
sum
of
the
same
bit
pattern
at
a
later
time.

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the HP HP-16C and is the answer not in the manual?

HP HP-16C Specifications

General IconGeneral
BrandHP
ModelHP-16C
CategoryDesktop
LanguageEnglish

Related product manuals