Section 10: Program Editing 143
File name: hp 12c pt_user's guide_English_HDPMF123E27 Page: 143 of 275
Printed Date: 2005/8/1 Dimension: 14.8 cm x 21 cm
4. Key in the original instruction or instructions, beginning with the first
instruction to be executed after the added instruction(s), and continuing
through the last instruction you keyed into program memory.
Note: If program memory includes branches to program lines following that
at which the first new instruction is being added, remember to change the
line number(s) specified in the i instruction(s) — as described above
under Changing the Instruction in a Program Line — to the actual new line
number(s).
Example:
Assuming you have made the program modifications as in the
preceding example, suppose you now wanted to insert a
t
instruction before
the program calculates net income after tax so that the program will display the
amount of the tax before displaying the net income after tax. The program should
be modified by making the changes below:
Keystrokes
(RPN mode)
Display
fs
Sets calculator to Program mode.
gi.
008
008, 25
Sets calculator to last program
line to be executed, which
contains the
b
instruction.
t
009, 31
Keys in new instruction.
-
010, 30
Keys in original instruction, which
was replaced by new instruction
added.
fs
12,000.00
Sets calculator back to Run mode.
15000
t
3,000.00
Twenty percent tax on $15,000
income.
t
12,000.00
Net income after tax.
Keystrokes
(ALG mode)
Display
fs
Sets calculator to Program mode.
gi.
011
011, 36
Sets calculator to last line keyed
into program memory for original
program.
t
012, 31
Keys new instruction into
program line 012.