252
Programming
IF SIDES<2 THEN
MSGBOX("Must be >= 2");
END;
UNTIL SIDES>=2;
END;
// specify num times to roll the dice.
VIEWS "Set Rolls",SETROLLS()
BEGIN
REPEAT
INPUT(ROLLS,"Num of Rolls","N = ","Enter
num rolls",10);
FLOOR(ROLLS) ROLLS;
IF ROLLS<1 THEN
MSGBOX("You must enter a number >= 1");
END;
UNTIL ROLLS>=1;
END;
Plot()
BEGIN
-1 Xmin;
MAX(D1)+1 Xmax;
0 Ymin;
MAX(D2)+1 Ymax;
STARTVIEW(1,1);
END;
The
ROLLMANY()
routine is another adaptation from a
program presented previously in this chapter. Since you
cannot pass parameters into a program called through a
selection from a custom Views menu, the exported
variables
SIDES
and
ROLLS
are used in place of the
parameters that were used in the previous versions.
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 ...