login
Numbers k such that k and k^2 use only the digits 2, 5, 6, 8 and 9.
1

%I #9 Apr 12 2024 09:51:27

%S 5,25,925,2585,2925,22925,25665,25865,28685,28686,228685,256565,

%T 258565,828665,925525,925665,926565,962585,2286685,2299686,2925525,

%U 2926925,9266565,22866685,22866925,22925865,22955585,22955665,25662585,28686685,29266925,29296585,29825865,29882585,29926565,82882585,92566565,92895565,96259685

%N Numbers k such that k and k^2 use only the digits 2, 5, 6, 8 and 9.

%C Generated with DrScheme.

%H Jonathan Wellons, <a href="/A137114/b137114.txt">Table of n, a(n) for n = 1..230</a>

%H J. Wellons, <a href="https://web.archive.org/web/20090206165028/http://jonathanwellons.com/shared-digits/">Tables of Shared Digits</a> [archived]

%e 829629856598686^2 = 688285698959956296296856926596.

%t Module[{c={2,5,6,8,9}},Table[Select[FromDigits/@Tuples[c,n],SubsetQ[ c, IntegerDigits[#^2]]&],{n,8}]]//Flatten (* _Harvey P. Dale_, Oct 21 2016 *)

%K base,nonn

%O 1,1

%A Jonathan Wellons (wellons(AT)gmail.com), Jan 22 2008