A387242 a(n) is the least k such that A334676(k) != k and the decimal string of n appears in A334676(k).
2, 42, 26, 28, 102, 32, 85, 172, 95, 20, 22, 242, 26, 28, 302, 32, 85, 236, 95, 402, 42, 442, 115, 482, 502, 522, 162, 562, 145, 260, 62, 1615, 266, 268, 712, 272, 148, 772, 278, 802, 82, 842, 215, 882, 902, 92, 235, 962, 245, 1002, 102, 1042, 265, 1078, 1102, 112, 285, 1162
Offset: 1
Examples
A334676(242) = 121, the first term whose decimal expansion contains the substring "12"; hence a(12) = 242. A334676(21) = A334676(42) = 21 contains "2" but a(2) = 42 since the first does not satisfy A334676(k) != k.
Crossrefs
Cf. A334676.
Programs
-
Python
# uses A334676() and neighs() from A334676 from itertools import count, islice def subs(s): yield from (s[i:j] for i in range(len(s)) for j in range(i+1, len(s)+1)) def agen(): # generator of terms adict, n = dict(), 1 for k in count(1): v = A334676(k) if v != k: for t in subs(str(v)): if (ti:=int(t)) not in adict: adict[ti] = k while n in adict: yield adict[n] n += 1 print(list(islice(agen(), 70))) # Michael S. Branicky, Aug 23 2025
Comments