OFFSET
1,2
COMMENTS
The number after 1 has to be 4, because the product 1*4 must be composite.
Then 2 is OK, because 4*2 = 8 is composite.
Then 3, because 2*3 = 6 is composite, and so on.
Note that 14 is the term after 9 because 10 is now the smallest candidate, but 10 has a 0 digit, 11 consists of two unit digits, and 12 and 13 have digit products 2 and 3, which are prime. - T. D. Noe, Apr 25 2012
LINKS
Dominic McCarty, Table of n, a(n) for n = 1..10000
PROG
(Python)
a, z = [1], [1, 2, 3, 5, 7]
while len(a) < 100:
k, s = 2, "2"
while (k in a) or ("0" in s) or (a[-1] % 10 * int(s[0]) in z) or \
any(int(s[n]) * int(s[n+1]) in z for n in range(0, len(s)-1)): s, k = str(k+1), k+1
a.append(k)
print(a) # Dominic McCarty, Jan 30 2025
CROSSREFS
KEYWORD
nonn,base,easy,nice
AUTHOR
Jim Nastos and Eric Angelini, Apr 22 2012
STATUS
approved