HP 20b: +/- and ANS (or CHS and LASTx)

HP 20b Using the RPN stack to solve problems efficiently

This solution works on all RPN-calculators I know but gives -0.91 on HP 20b instead. The reason is that +/- copies register X to ANS. Thus the 2nd ANS returns 1/x instead of x.

Microchallenge: Can you help HP and find the correct sequence?

Here's the link to get all HP 20b Training Modules.



Despite the fact the 20b has a RPN mode, it has a strange "new" behaviour, contrary to the also new 35s and the dozens of classic hp RPN calculators:

ENTER after numeric keystrokes doesn't copy X to Y but it does only finalize the input buffer (it isn't X) and copy it to the 1st stack register in 20s.

Incredible, but it works like the high end RPL models. I don't know why they choose to change this important detail of RPN input paradigma...

Back to topic: That's why there is one more INPUT keystroke in my proposition below.

Possible solution

3,4567 INPUT


shift SQR


shift LN




shift 1/x


20 keystrokes and right answer: 4,05


You've cheated a little since ANS is shifted. But still we can do it with 20 keystrokes:

shift SQRT
shift ANS
shift LN
shift 1/x

Possibly Related Threads…
Thread Author Replies Views Last Post
  HP-80 CHS Exponent Curiosity Max Stone 4 1,838 10-22-2013, 02:39 PM
Last Post: Max Stone
  HP's thinking behind the 20b/30b? John Ioannidis 3 1,633 09-07-2013, 10:21 AM
Last Post: Tim Wessman
  20b, 30b not in HP's web store Eric Smith 3 1,447 02-08-2013, 11:52 AM
Last Post: Walter B
  A non 20b/30b 34S Matt Agajanian 22 5,120 08-20-2012, 01:06 AM
Last Post: Reth
  [WP-34s] IR conversion of 20b Alexander Oestert 3 1,513 05-18-2012, 05:38 PM
Last Post: Harald
  LASTx for the 35 Matt Agajanian 3 1,345 03-23-2012, 03:29 AM
Last Post: Massimo Gnerucci (Italy)
  WP 34S - INC X and RCL L (LASTx) Gerson W. Barbosa 10 2,480 12-26-2011, 05:33 PM
Last Post: Paul Dale
  Why hp-20b more expensive than 30b? Masaki Adachi 9 2,901 10-14-2011, 12:08 PM
Last Post: megarat
  missing segments on 20b running 34s db (martinez, ca.) 4 1,620 10-05-2011, 01:27 AM
Last Post: Walter B
  Flashing HP 20b for WP 34S Steve Brenton 10 2,663 09-30-2011, 09:03 AM
Last Post: Marcus von Cube, Germany

Forum Jump: