Post Reply 
Algorithm for entering numbers?
08-11-2019, 05:06 PM (This post was last modified: 08-11-2019 05:06 PM by Ángel Martin.)
Post: #3
RE: Algorithm for entering numbers?
We take all this for granted, I had the same thoughts when putting together the 41Z while working on the Complex Stack rules.

The key is the stack lift CPU flag (SL for short). If the flag is enabled, the content of X is pushed into Y, and if 'it's disabled it's not.

The first digit of the number you type pushes X into Y and disables the SL flag. When you're done typing digits and press ENTER, that enables the SL again.

the SL is enabled most of the time, like right after the 1/X function and pretty every other function for that matter - that ensures the proper dynamics of the RPN stack.

Some exceptions: CLX disables the SL, as usually it's done as part of the digit entry sequence.

Cheers,
ÁM
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
Algorithm for entering numbers? - rea5245 - 08-11-2019, 04:36 PM
RE: Algorithm for entering numbers? - Ángel Martin - 08-11-2019 05:06 PM



User(s) browsing this thread: 1 Guest(s)