EasyManuals Logo

HP 12C User Manual

HP 12C
278 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 #129 background imageLoading...
Page #129 background image
Section 9: Branching and Looping 129
File name: hp 12c pt_user's guide_English_HDPMF123E27 Page: 129 of 275
Printed Date: 2005/8/1 Dimension: 14.8 cm x 21 cm
Keystrokes Display
t
–592.25
Portion of third month’s payment
applied to interest.
–190.22
Portion of third month’s payment
applied to principal.
t
(or any key)
–190.22
Halts program execution.
Conditional Branching
Often there are situations when it is desirable for a program to be able to branch
to different lines in program memory, depending on certain conditions. For
example, a program used by an accountant to calculate taxes might need to
branch to different program lines depending on the tax rate for the particular
income level.
The hp 12c platinum provides two conditional test instructions that are used in
programs for conditional branching:
z g o tests whether the number in the X-register (represented by the x in the
key symbol) is less than or equal to the number in the Y-register (represented
by the y in the key symbol). As discussed in Appendix A, the number in the
X-register is simply the number that would, if the calculator were in Run mode,
be currently in the display; and the number in the Y-register is the number
that would, if the calculator were in Run mode, have been in the display
when \ was pressed. For example, pressing 4\5 would place the
number 4 in the Y-register and the number 5 in the X-register.
z g m tests whether the number in the X-register is equal to zero.
The possible results of executing either of these instructions are:
z If the condition tested for is true when the instruction is executed, program
execution continues sequentially with the instruction in the next line of
program memory.
z If the condition tested for is false when the instruction is executed, program
execution skips the instruction in the next line of program memory and
continues with the instruction in the following line.

Table of Contents

Other manuals for HP 12C

Questions and Answers:

Question and Answer IconNeed help?

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

HP 12C Specifications

General IconGeneral
TypeFinancial Calculator
DisplayLCD, 10 digits
ManufacturerHewlett-Packard
ProgrammingKeystroke
Memory20 memory registers
Functionsstatistical functions
Dimensions12.7 x 7.87 x 1.52 cm (5 x 3.1 x 0.6 in)

Related product manuals