HP Forums
Challenge: Generate a 64 in the display (RPN) - Printable Version

+- HP Forums (https://www.hpmuseum.org/forum)
+-- Forum: HP Calculators (and very old HP Computers) (/forum-3.html)
+--- Forum: General Forum (/forum-4.html)
+--- Thread: Challenge: Generate a 64 in the display (RPN) (/thread-15529.html)

Pages: 1 2 3 4


RE: Challenge: Generate a 64 in the display (RPN) - grsbanks - 09-03-2020 10:53 AM

I've got it down to 2 steps and 4 bytes on a 42S but I'm not sure how I can get it that low on a 41C.


RE: Challenge: Generate a 64 in the display (RPN) - Gene - 09-03-2020 11:02 AM

(09-03-2020 06:10 AM)Werner Wrote:  Gene: 'generate a 64 in the X-register'
.. that is not quite the same as saying 'generate the number 64 in the X-reg', is it?
in that case:
41C: 3 steps
Werner

Gene: My intent was to have the X register having the number 64, regardless of the original stack or any other initial settings of the calculator.


RE: Challenge: Generate a 64 in the display (RPN) - Werner - 09-03-2020 11:17 AM

In that case, 41C: 5 steps
Werner


RE: Challenge: Generate a 64 in the display (RPN) - grsbanks - 09-03-2020 11:27 AM

I've got it down to 4 steps on a 41CX (or 41C/CV with an X-Func module).
Edit: Make that 3 steps.


RE: Challenge: Generate a 64 in the display (RPN) - Gene - 09-03-2020 11:59 AM

Maybe we need two separate categories :-)

Those using common functions across most machines (+ - SIN COS LN X<>Y) etc. and those using functions only found on one machine? :-)

I am looking forward to the seemingly wide variety of responses. None of them will be out of bounds but likely to generate "Why didn't I think of that?"

feel free to start posting actual solutions at noon central time USA (that's 5 hours from this post).


RE: Challenge: Generate a 64 in the display (RPN) - Andres - 09-03-2020 01:14 PM

Agree, too. For HP 42S, 2 steps, 4 bytes (but not quite 2 keystrokes!)


RE: Challenge: Generate a 64 in the display (RPN) - Mark Hardman - 09-03-2020 01:27 PM

(09-03-2020 05:23 AM)Valentin Albillo Wrote:  
(09-03-2020 04:43 AM)Mark Hardman Wrote:  HP42s - 5 steps

Edit: 4 steps
Edit 2: 3 steps

In the HP42s and some models of the 41 it can be done in 2 steps.

V.

I start with a CLA just in case the calculator is already in Alpha mode with some characters entered.


RE: Challenge: Generate a 64 in the display (RPN) - Thomas Okken - 09-03-2020 01:51 PM

(09-03-2020 01:27 PM)Mark Hardman Wrote:  
(09-03-2020 05:23 AM)Valentin Albillo Wrote:  In the HP42s and some models of the 41 it can be done in 2 steps.

V.

I start with a CLA just in case the calculator is already in Alpha mode with some characters entered.

That is not necessary. The two-step solution works regardless of the initial state of the calculator.


RE: Challenge: Generate a 64 in the display (RPN) - pinkman - 09-03-2020 02:39 PM

Am I the only one not finding it?...!!!

Ps: I don’t want a clue, I just wanted to complainSmile


RE: Challenge: Generate a 64 in the display (RPN) - grsbanks - 09-03-2020 02:40 PM

(09-03-2020 12:47 PM)Albert Chan Wrote:  HP-12C, 8 steps, 2^6 = 64

Code:
CLX
E^X
...

Very nice but we're not supposed to start posting solutions until 12pm Central Time, so that's 17:00 UTC.


RE: Challenge: Generate a 64 in the display (RPN) - Albert Chan - 09-03-2020 02:47 PM

(09-03-2020 02:40 PM)grsbanks Wrote:  Very nice but we're not supposed to start posting solutions until 12pm Central Time, so that's 17:00 UTC.

Sorry, I mis-read the time as deadline. Post deleted.


RE: Challenge: Generate a 64 in the display (RPN) - Mark Hardman - 09-03-2020 03:18 PM

(09-03-2020 01:51 PM)Thomas Okken Wrote:  
(09-03-2020 01:27 PM)Mark Hardman Wrote:  I start with a CLA just in case the calculator is already in Alpha mode with some characters entered.

That is not necessary. The two-step solution works regardless of the initial state of the calculator.

After two seconds reflection it is obvious that the extra CLA is not necessary. What was I thinking?

HP42s - 2 steps, 4 bytes


RE: Challenge: Generate a 64 in the display (RPN) - Valentin Albillo - 09-03-2020 03:19 PM

.
Hi, all:

I think it's well past the deadline so I'm posting here my solutions in the clear, but first of all let me say that when issuing or taking a challenge, the wording is essential, you should mean non-ambiguously exactly what you mean if you're issuing the challenge and you should read exactly what was written when taking it.

Gene says classic (not "Classic", "The Classics (1972)", etc.) and Gene says steps, not keystrokes, etc.

For the HP42S (and some models of HP-41), my 2-step solution is:

      01 "@"
      02 ATOX


For the HP-25 and many, many other models my 7-step solutions are:

      PI, ENTER, y^x, PI, SQRT, *, INT

or

      CLX, EXP, EXP, PI, *, INT, X^2


Nice little challenge, Gene, thank you !

Regards.
V.


RE: Challenge: Generate a 64 in the display (RPN) - Sylvain Cote - 09-03-2020 03:28 PM

(09-03-2020 03:19 PM)Valentin Albillo Wrote:  For the HP42S (and some models of HP-41), my 2-step solution is:
      01 "@"
      02 ATOX
Same here! (HP-42S, HP-41C+XFM, HP-41CV+XFM & HP-41CX)


RE: Challenge: Generate a 64 in the display (RPN) - grsbanks - 09-03-2020 03:40 PM

(09-03-2020 03:19 PM)Valentin Albillo Wrote:  I think it's well past the deadline

Nope. Not for another 80 minutes.

How do you get "@" in the alpha register? My 3-step solutions use other characters and one operation to adjust the ASCII code to 64.


RE: Challenge: Generate a 64 in the display (RPN) - Gene - 09-03-2020 03:55 PM

Time is not constant. :-)

Ok, deadline lifted. Let's see those solutions!


RE: Challenge: Generate a 64 in the display (RPN) - Mark Hardman - 09-03-2020 03:55 PM

Code:
00 { 4-Byte Prgm }
01 "@"
02 ATOX
03 .END.



RE: Challenge: Generate a 64 in the display (RPN) - Gerson W. Barbosa - 09-03-2020 03:57 PM

HP-41C:

01 CLX
02 E↑X
03 10↑X
04 DEC
05 X↑2
06 END


HP-42S:

00 { 4-Byte Prgm }
01 "@"
02 ATOX
03 END



RE: Challenge: Generate a 64 in the display (RPN) - Sylvain Cote - 09-03-2020 04:52 PM

(09-03-2020 03:40 PM)grsbanks Wrote:  How do you get "@" in the alpha register? My 3-step solutions use other characters and one operation to adjust the ASCII code to 64.
Direct with: CCD ROM, ZENROM, CCD-OSX, etc
Synthetic with: Byte Grabber, etc


RE: Challenge: Generate a 64 in the display (RPN) - Massimo C. - 09-03-2020 05:22 PM

HP 35s: 4 steps

<-
-> °F
ENTER
+