Getting usable numbers from a Program Preferrably on Stack
|
05-15-2021, 09:39 AM
Post: #1
|
|||
|
|||
Getting usable numbers from a Program Preferrably on Stack
I have written a little program to help my day to day business, that will convert feet and inches into metres. The program will currently return the metres value to the stack, and that is a good start.
I wonder if there would be a way to have the feet and inches values also sent to the stack for future viewing, not just to the terminal window. While i'm asking about sending numbers to stack from a program, is there any way to put more than one single number to stack, so that I can scroll up and see it, or press enter on it, to use it in a future calculation. Thanks for any help. |
|||
05-15-2021, 03:59 PM
Post: #2
|
|||
|
|||
RE: Getting usable numbers from a Program Preferrably on Stack
The RETURN command can return a list or vector of values to the stack, not just one value.
|
|||
05-15-2021, 04:02 PM
Post: #3
|
|||
|
|||
RE: Getting usable numbers from a Program Preferrably on Stack
(05-15-2021 03:59 PM)Eddie W. Shore Wrote: The RETURN command can return a list or vector of values to the stack, not just one value. That's great, I assume that the individual values of the lists will be usable as separate numbers on the stack, so I could go to one of them and press enter, and that single number would be brought to the current calculation line? Thanks for the reply. |
|||
05-16-2021, 06:33 AM
(This post was last modified: 05-16-2021 06:36 AM by Stevetuc.)
Post: #4
|
|||
|
|||
RE: Getting usable numbers from a Program Preferrably on Stack
(05-15-2021 04:02 PM)matalog Wrote:(05-15-2021 03:59 PM)Eddie W. Shore Wrote: The RETURN command can return a list or vector of values to the stack, not just one value. And see this thread. https://www.hpmuseum.org/forum/thread-16946.html A user defined key can return a string containing multiple values space separated to the command line. Pressing Enter will place those values as separate numbers on the stack. In the code below, userkey Shift User 2 will place 4 3 2 1 on the RPN command line. Pressing Enter will place the following into Stack levels 1-4 4 (stack 4) 3 2 1 (stack 1) Code:
|
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 2 Guest(s)