HP (Hewlett-Packard) 39g+ Calculator User Manual


 
16-26 Programming
CHOOSE Creates a choose box, which is a box containing a list of
options from which the user chooses one. Each option is
numbered, 1 through n. The result of the choose
command is to store the number of the option chosen in a
variable. The syntax is
CHOOSE default_option_number; title; option
1
;
option
2
; ...option
n
:
where default_option_number is the number of the option
that will be highlighted by default whenever the choose
box is displayed, title is the text displayed in the title bar
of the choose box, and option
1
...option
n
are the options
listed in the choose box.
Example
3 X A:CHOOSE A;
"COMIC STRIPS";
"DILBERT";
"CALVIN&HOBBES";
"BLONDIE":
DISP Displays textitem in a row of the display at the
line_number. A text item consists of any number of
expressions and quoted strings of text. The expressions
are evaluated and turned into strings. Lines are numbered
from the top of the screen, 1 being the top and 7 being
the bottom.
DISP line_number;textitem:
Example
DISP 3;"A is" 2+2
Result: A is 4
(displayed on line 3)
DISPTIME Displays the current date and time.
DISPTIME
To set the date and time, simply store the correct settings
in the date and time variables. Use the following formats:
M.DDYYYY for the date and H.MMSS for the time.