login
Numbers k such that k and k^2 use only the digits 0, 1, 4 and 8.
1

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

%S 0,1,10,100,1000,10000,10401,100000,104010,1000000,1004001,1040100,

%T 10000000,10040010,10401000,100000000,100040001,100400100,104010000,

%U 1000000000,1000400010,1004001000,1040100000,10000000000,10000400001,10004000100,10040010000,10401000000,100000000000,100004000010,100040001000,100400100000

%N Numbers k such that k and k^2 use only the digits 0, 1, 4 and 8.

%C Generated with DrScheme.

%H Jonathan Wellons, <a href="/A136866/b136866.txt">Table of n, a(n) for n = 1..55</a>

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

%e 100004040010401^2 = 10000808018401884040188180801.

%t With[{c={0,1,4,8}},Select[FromDigits/@Tuples[c,12],SubsetQ[ c, IntegerDigits[ #^2]]&]] (* _Harvey P. Dale_, Oct 06 2020 *)

%K base,nonn

%O 1,3

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