OFFSET
0,1
COMMENTS
a(29) = 43624023.
LINKS
Giovanni Resta, Table of n, a(n) for n = 0..43
MATHEMATICA
f[n_] := Block[{s = Split[ Boole[ EvenQ@# & /@ RealDigits[Sqrt@ n, 10, 32][[1]]]][[1]]}, If[IntegerQ@ Sqrt@ n || Union@ s == {0}, -1, Length@ s]]; t = Table[0, {30}]; k = 2; While[k < 100000001, a = f@ k; If[t[[a]] == 0, t[[a]] = k; Print[{a, k}]]; k++]; t
PROG
(PARI) a(n) = {my(g=10^n, v); for(k=2, oo, v=digits(floor(sqrt(k)*g))[1..n+1]; if(v[n+1]%2 && setintersect([0, 2, 4, 6, 8], v=Set(v[1..n]))==v && !issquare(k), return(k))); } \\ Jinyuan Wang, Apr 16 2020
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Robert Israel and Robert G. Wilson v, Jan 23 2013
EXTENSIONS
a(25) from Jinyuan Wang, Apr 16 2020
a(25) corrected and more terms from Giovanni Resta, Apr 18 2020
STATUS
approved