logoalt Hacker News

Someonetoday at 6:00 AM1 replyview on HN

For a limit of 10,000⁵. Reading https://www.ams.org/journals/mcom/1967-21-097/S0025-5718-196... the original search seems to have gone up to 250⁵. That’s a search space that’s 40⁵ ≈ 10⁸ larger.

They also forget to break out of the loops when the sum of, say, the first three fifth powers already is larger than 10,000⁵.


Replies

nroetstoday at 6:25 AM

It's likely that the original search also used strength reduction to save a lot of cycles (effectively replacing all multiplications with additions):

https://en.wikipedia.org/wiki/Strength_reduction