%I #19 Apr 03 2023 18:23:41
%S 0,1,5,10,25,50,65,100,146,250,405,500,510,521,615,650,768,945,965,
%T 1000,1004,1040,1050,1085,1126,1145,1203,1216,1219,1222,1452,1460,
%U 1476,1480,1482,1638,1706,1878,2002,2020,2199,2204,2260,2276,2326,2450,2470,2476
%N Numbers k such that digits of k^3 include digits of k^2.
%e a(8) = 146 because 146^3 = 3112136 includes all digits of 146^2 = 21316.
%o (Python)
%o from itertools import count, islice
%o from collections import Counter
%o def A045620_gen(startvalue=0): # generator of terms >= startvalue
%o return filter(lambda k:Counter(str(m:=k**2))<=Counter(str(k*m)),count(max(startvalue,0)))
%o A045620_list = list(islice(A045620_gen(),20)) # _Chai Wah Wu_, Apr 03 2023
%Y Cf. A029772, A046827, A046829.
%K easy,nonn,base
%O 1,3
%A _Erich Friedman_
%E Edited by _N. J. A. Sloane_, Nov 01 2007, at the suggestion of _Alexander R. Povolotsky_
|