login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A046831
Numbers k such that decimal expansion of k^2 contains k as a substring and k does not end in 0.
8
1, 5, 6, 25, 76, 376, 625, 3792, 9376, 14651, 90625, 109376, 495475, 505025, 890625, 971582, 1713526, 2890625, 4115964, 5133355, 6933808, 7109376, 10050125, 12890625, 48588526, 50050025, 66952741, 87109376, 88027284, 88819024
OFFSET
1,2
COMMENTS
Subsequence of A018834. - Chai Wah Wu, Apr 04 2023
LINKS
MATHEMATICA
Reap[For[n = 1, n < 10^8, n++, If[Mod[n, 10] != 0, If[StringPosition[ToString[n^2], ToString[n]] != {}, Print[n]; Sow[n]]]]][[2, 1]] (* Jean-François Alcover, Apr 04 2013 *)
PROG
(Haskell)
a046831 n = a046831_list !! (n-1)
a046831_list = filter ((> 0) . (`mod` 10)) a018834_list
-- Reinhard Zumkeller, Jul 27 2011
(Python)
from itertools import count, islice
def A046831_gen(startvalue=0): # generator of terms >= startvalue
return filter(lambda n:n%10 and str(n) in str(n**2), count(max(startvalue, 0)))
A046831_list = list(islice(A046831_gen(), 20)) # Chai Wah Wu, Apr 04 2023
CROSSREFS
KEYWORD
nonn,base
STATUS
approved