
Page 21-23
@SST
↓
@
Result: a:2
@SST
↓
@
Result: empty stack, executing
→
a
@SST
↓
@
Result: empty stack, entering subprogram
«
@SST
↓
@
Result: ‘2*a^2+3’
@SST
↓
@
Result: ‘2*a^2+3’, leaving subprogram
»
@SST
↓
@
Result: ‘2*a^2+3’, leaving main program
»
Further pressing the
@SST
↓
@
soft menu key produces no more output since we
have gone through the entire program, step by step. This run through the
debugger did not provide any information on why the program is not
calculating the value of
2a
2
+3
for a = 2. To see what is the value of a in the
sub-program, we need to run the debugger again and evaluate a within the
sub-program. Try the following:
J
Recovers
variables
menu
³
@FUNCa
`
Copies program name to stack level 1
„°LL
@)@RUN@ @@DBG@
Starts
debugger
@SST
↓
@
Step-by-step debugging, result: “Enter a:”
@SST
↓
@
Result:
{“
a:” {2 0} V}
@SST
↓
@
Result: user is prompted to enter value of a
2`
Enter a value of 2 for a. Result: “
:a:2”
@SST
↓
@
Result:
a:2
@SST
↓
@
Result:
empty
stack,
executing
→
a
@SST
↓
@
Result: empty stack, entering subprogram
«
At this point we are within the subprogram
«
‘
2*a^2+3
’
»
which uses the
local variable a. To see the value of a use:
~„aµ
This indeed shows that the local variable a = 2
Let’s kill the debugger at this point since we already know the result we will
get. To kill the debugger press
@KILL
. You receive an
<!> Interrupted
message acknowledging killing the debugger. Press
$
to recover normal
calculator display.
Note
: In debugging mode, every time we press
@SST
↓
@
the top left corner of the
display shows the program step being executed. A soft key function called
@@SST@
is also available under the
@)RUN
sub-menu within the PRG menu.
Содержание 49g+
Страница 1: ...hp 49g graphing calculator user s guide H Edition 4 HP part number F2228 90006 ...
Страница 197: ...Page 5 30 LIN LNCOLLECT POWEREXPAND SIMPLIFY ...
Страница 377: ...Page 11 55 Function KER Function MKISOM ...
Страница 457: ...Page 13 26 In the right hand side figure above we are using the line editor to see the series expansion in detail ...
Страница 775: ...Page 26 10 the location of the backup battery in the top compartment at the back of the calculator ...
Страница 838: ...Page L 5 ...