274
Programming
program, if variables
a
and
b
are not declared and
X
is
90, then
expr
(
"2X+a+b"
) returns 180+a+b.
When used in tandem with other functionality built-in to
the HP39gII, the
expr
command can be used in powerful
ways. For example, you could build functions up out of
strings and export these functions so they can be used
throughout the calculator.
string
Syntax:
string
(
object
);
Returns a string representation of the
object
. The result
varies depending on the type of
object
. For example,
string
(
2/3
); results in
string
(
"2/3"
)
Examples:
inString
Syntax:
inString
(
str1,str2
)
Returns the index of the first occurrence of
str2
in
str1
.
Returns 0 if
str2
is not present in
str1
. Note that the first
character in a string is a position
1
.
Examples:
inString
(
"vanilla","van"
) returns 1.
inString
(
"banana","na"
) returns 3
inString
(
"ab","abc"
) returns 0
String
Result
string
(2/3)
"2/3"
string
(2.0/3)
"0.666666666667"
string
(F1), when F1(X)
= COS(X)
"(X)->COS(X)"
string
(L1) when L1 =
{1,2,3}
"1,2,3"
string
(M1) when M1 =
"[1,2,3],[4,5,6]"
1 2 3
4 5 6
Summary of Contents for 39gII
Page 1: ...HP 39gII graphing calculator user s guide Edition1 Part Number NW249 90001 ...
Page 2: ...Printing History Edition 1 November 201 1 ...
Page 32: ...22 Getting started ...
Page 58: ...48 Apps and their views ...
Page 70: ...60 Function app ...
Page 80: ...70 Solve app ...
Page 136: ...126 Polar app ...
Page 140: ...130 Sequence app ...
Page 148: ...138 Finance app ...
Page 152: ...142 Linear Solver app ...
Page 218: ...208 Matrices ...
Page 226: ...216 Notes and Info ...
Page 238: ...228 Variables and memory management ...
Page 318: ...308 Programming ...
Page 340: ...330 Reference information ...
Page 346: ...vi Product Regulatory Information ...