HP-25/SR-56 Identical Conditionals
|
10-14-2021, 04:18 PM
Post: #12
|
|||
|
|||
RE: HP-25/SR-56 Identical Conditionals
(10-14-2021 12:38 PM)Valentin Albillo Wrote:(10-14-2021 11:38 AM)Dave Britten Wrote: I've had the occasional situation on an HP where it would be nice to decrement a counter and execute the next instruction only if the counter is now zero, but it's not super common. You can usually get around it with a GTO or some test that will always be false, but it's not quite as clean. I don't have a specific example on the tip of my tongue, but the general pattern usually ends up being something like this on an HP: Code:
i.e. when you need to decrement a counter and break out of the loop when the counter reaches its end, but you need to do this in the middle of the loop body. On a TI you can replace the exit test with something like INV 2nd DSZ 04 9' to break out of the loop when the counter hits 0. Slightly more elegant, but it's a small victory with how much less elegant a lot of programming constructs are on the TI-59/58. |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)