Talk:First perfect square in base n with n unique digits: Difference between revisions
Talk:First perfect square in base n with n unique digits (view source)
Revision as of 16:28, 27 May 2019
, 4 years agoAdded section about a minor optimization.
Thundergnat (talk | contribs) (→analytically determine minimum start value: Ah. My mishandling of square root calculations.) |
(Added section about a minor optimization.) |
||
Line 344:
</lang>
rSet(20) -> {0, 1, 4, 5, 9, 16}<br>--[[User:Nigel Galloway|Nigel Galloway]] ([[User talk:Nigel Galloway|talk]]) 17:02, 25 May 2019 (UTC)
==Trailing zero==
A minor optimization has occurred to me namely that N cannot end with '0', whatever the base, because if it did, then N² would end with '00'.
However, this is impossible because:
* if N² has 'base' digits, it can't then be pandigital; or
* if N² has 'base+1' digits then the repeated digit would be zero and so the digital root would be unchanged.
<br>
As checking for this is very cheap, it may knock about 4 or 5% from the run time for bases >= 20.
--[[User:PureFox|PureFox]] ([[User talk:PureFox|talk]]) 16:27, 27 May 2019 (UTC)
|