The Museum of HP Calculators

HP Forum Archive 21

[ Return to Index | Top of Index ]

HP 39gii Tutorials Parts 1 and 2 up
Message #1 Posted by Eddie W. Shore on 9 Mar 2013, 1:41 p.m.

Part 1: PRINT, INPUT, string

Part 2: IF/THEN/ELSE/END, MSGBOX, CHOOSE

      
Re: HP 39gii Tutorials Parts 1 and 2 up
Message #2 Posted by Gilles Carpentier on 10 Mar 2013, 4:49 a.m.,
in response to message #1 by Eddie W. Shore

Well done !

About PRINT command, as far I know it is not explain in the user guide, but you can use PRINT without any parameter to clear the screen. There is no CLS or CLEAR command, PRINT do the job

Another trick not explain is that you can easily create new global variables with just the syntax (in a program):

EXPORT NewGlobal ;

For example

EXPORT L10:={};

create a new global list in addition of the existing L0..L9

There is no need of 'string' command in such things as :

EXPORT AREA1() BEGIN INPUT(R, "Radius"); PRINT("THE AREA IS " + string(Pi*Rē) + "."); END;

PRINT("THE AREA IS " + Pi*Rē + "."); is OK

To evaluate in expresion in a string, the command is expr expr("2+3") returns 5. If the variable X has the value 90, then expr("X+10") returns 100.

I also notice that the 39GII knows some physics contants (Math - PHYS ) but I don't know if wecan use them in program. It would simplify your program KEPLER (with a powerfull unit management in addition)

Edited: 10 Mar 2013, 5:19 a.m.

            
Re: HP 39gii Tutorials Parts 1 and 2 up
Message #3 Posted by Eddie W. Shore on 11 Mar 2013, 8:22 a.m.,
in response to message #2 by Gilles Carpentier

Quote:
Well done !

About PRINT command, as far I know it is not explain in the user guide, but you can use PRINT without any parameter to clear the screen. There is no CLS or CLEAR command, PRINT do the job

Another trick not explain is that you can easily create new global variables with just the syntax (in a program):

EXPORT NewGlobal ;

For example

EXPORT L10:={};

create a new global list in addition of the existing L0..L9

There is no need of 'string' command in such things as :

EXPORT AREA1() BEGIN INPUT(R, "Radius"); PRINT("THE AREA IS " + string(Pi*Rē) + "."); END;

PRINT("THE AREA IS " + Pi*Rē + "."); is OK

To evaluate in expresion in a string, the command is expr expr("2+3") returns 5. If the variable X has the value 90, then expr("X+10") returns 100.

I also notice that the 39GII knows some physics contants (Math - PHYS ) but I don't know if wecan use them in program. It would simplify your program KEPLER (with a powerfull unit management in addition)


Thanks!

I note that string is not necessary. However, what if the expression has addition in it (a+b for example)? Staying on the safe side - I think.

Units in programs would help - not sure if I can use them. I was not able to use units in the Solver app.

      
Re: HP 39gii Tutorials Parts 1 and 2 up
Message #4 Posted by Herman T on 11 Mar 2013, 7:43 a.m.,
in response to message #1 by Eddie W. Shore

Nice, thank you. Herman


[ Return to Index | Top of Index ]

Go back to the main exhibit hall