login
n, n^2 and n^3 all use only even digits.
0

%I #15 Oct 05 2013 02:09:20

%S 0,2,20,200,202,2000,2002,2020,20000,20002,20020,20200,200000,200002,

%T 200020,200200,202000,2000000,2000002,2000020,2000200,2002000,2020000,

%U 20000000,20000002,20000020,20000200,20000202,20002000,20002002,20020000

%N n, n^2 and n^3 all use only even digits.

%C Subsequence of A014263 and of A136904. - _Michel Marcus_, Oct 04 2013

%e 202 is a term because 202, 202^2=4008004 and 202^3=8024024008 all use only even digits.

%o (PARI) evdigs(n) = {if (n==0, return (1)); digs = digits(n); for (i = 1, #digs, if (digs[i] % 2, return (0));); return (1);}

%o isok(n) = evdigs(n) && evdigs(n^2) && evdigs(n^3); \\ _Michel Marcus_, Oct 04 2013

%Y Cf. A068690.

%K nonn,base

%O 1,2

%A _Zak Seidov_, Jul 06 2003

%E More terms from _Michel Marcus_ and _Jon E. Schoenfield_, Oct 04 2013