Programming puzzle: Longest list of regular numbers?
|
01-17-2021, 09:02 PM
(This post was last modified: 01-18-2021 06:02 PM by C.Ret.)
Post: #33
|
|||
|
|||
RE: Programming puzzle: Longest list of regular numbers?
Hi,
I may suggest changing your algorithm, I get up to the 3428th in 2min7sec on my HP-28S. The HP-50g have much more punch than my ageless HP-28S. I am sure you will break easily my record ! Feel free to adapt this HP-28S style code; Code: HAM: Where HRAZ is : Code: HRAZ: On HP-48/50g, faster algorithms may certainly exist storing 'H' as a list in order to take advantage of the built-in SORT instruction that may certainly spare run time. Such an instruction is missing on the HP-28s, to avoid sorting, I use a kind of rudimentary (but huge) hash-table; all 'H' values are in the range ] -1 ; 0 ], and relative order is kept for any slide 'X' ; no sorting require, just have to count non null value to extract the result ! Regards. C.Ret |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 4 Guest(s)