Identifying Output In Programs; Tagging A Numerical Result; De-Tagging" A Tagged Quantity - HP F2226A - 48GII Graphic Calculator User Manual

Graphing calculator
Table of Contents

Advertisement

the commands "Operation cancelled" MSGBOX will show a message
box indicating that the operation was cancelled.

Identifying output in programs

The simplest way to identify numerical program output is to "tag" the program
results. A tag is simply a string attached to a number, or to any object. The
string will be the name associated with the object.
For example, earlier on,
when debugging programs INPTa (or INPT1) and INPT2, we obtained as
results tagged numerical output such as :a:35.

Tagging a numerical result

To tag a numerical result you need to place the number in stack level 2 and
the tagging string in stack level 2, then use the →TAG function („ °
@) T YPE@ @
TAG) For example, to produce the tagged result B:5., use:
5`‚Õ~b„ ° @) T YPE@ @
TAG
Decomposing a tagged numerical result into a number and a tag
To decompose a tagged result into its numerical value and its tag, simply use
(„°@) T YPE@ @OBJ
@). The result of decomposing a tagged
function OBJ
number with →OBJ is to place the numerical value in stack level 2 and the tag
in stack level 1. If you are interested in using the numerical value only, then
you will drop the tag by using the backspace key ƒ. For example,
decomposing the tagged quantity B:5 (see above), will produce:

"De-tagging" a tagged quantity

"De-tagging" means to extract the object out of a tagged quantity. This
function is accessed through the keystroke combination: „ ° @) T YPE@
L @DTAG. For example, given the tagged quantity a:2, DTAG returns the
numerical value 2.
Page 21-33

Advertisement

Table of Contents
loading

This manual is also suitable for:

48gii

Table of Contents