HP 15C conditional does not behave as expected
|
05-07-2021, 06:45 PM
(This post was last modified: 05-07-2021 08:13 PM by Siegfried.)
Post: #5
|
|||
|
|||
RE: HP 15C conditional does not behave as expected
I think you got the loop label wrong which is .0 (corresponding to the GTO .0 at the end) which you have listed as
Code: 42 21 0 May I ask what your result is on program termination? I get the 894.xxx but that's wrong as the comparison should result in a few more loops and end up around 994. I get the same result on a real HP-15C and nonpareil-15c. I also tried this on a HP-41CX and get the same behaviour. I have added an R/S to check the stack before the conditional test and have verified X=894.5956 and Y=1. So when Testing X>Y? the result is TRUE and either calculator should continue on the line after the conditional test (that is the GTO .0 instruction) but it stops on the R/S one line further. (05-07-2021 04:22 PM)Gene Wrote: Works fine for me as you have written it out on a 15c emulator. Don't have the physical unit with me at the moment. |
|||
« Next Oldest | Next Newest »
|
Messages In This Thread |
HP 15C conditional does not behave as expected - Siegfried - 05-07-2021, 09:13 AM
RE: HP 15C conditional does not behave as expected - rprosperi - 05-07-2021, 12:17 PM
RE: HP 15C conditional does not behave as expected - Siegfried - 05-07-2021, 03:56 PM
RE: HP 15C conditional does not behave as expected - Gene - 05-07-2021, 04:22 PM
RE: HP 15C conditional does not behave as expected - Siegfried - 05-07-2021 06:45 PM
RE: HP 15C conditional does not behave as expected - Gene - 05-07-2021, 08:03 PM
RE: HP 15C conditional does not behave as expected - Siegfried - 05-07-2021, 08:19 PM
RE: HP 15C conditional does not behave as expected - Albert Chan - 05-07-2021, 08:25 PM
RE: HP 15C conditional does not behave as expected - Gene - 05-07-2021, 08:40 PM
RE: HP 15C conditional does not behave as expected - Siegfried - 05-07-2021, 09:04 PM
|
User(s) browsing this thread: 1 Guest(s)