OFFSET
1,2
LINKS
Michael S. Branicky, Table of n, a(n) for n = 1..10000 (terms 1..3494 from Carole Dubois)
EXAMPLE
The sequence starts with 1,11111,101111,110111,111011,111101,111110,11112,11113,... and we see indeed that a(2) = 11111 is the smallest available integer showing five digits that divide a(1) = 1; in the same manner we have a(3) = 101111 [the five 1s divide a(2) = 11111], a(4) = 110111 [the five 1s divide a(3) = 101111], a(8) = 11112 [all five digits divide a(7) = 111110], a(9) = 11113 [all five digits divide a(8) = 11112], etc.
PROG
(Python)
from itertools import count, islice
def cond(an, k):
return 5 == sum(1 for d in map(int, str(k)) if d and an%d == 0)
def agen(): # generator of terms
an, aset, m, mdict = 1, set(), 2, dict()
while True:
yield an
aset.add(an)
key = tuple(i for i in range(1, 10) if an%i == 0)
mm = max(mdict[key], m) if key in mdict else m
an = next(k for k in count(mm) if k not in aset and cond(an, k))
mdict[key] = an + 1
while m in aset: m += 1
print(list(islice(agen(), 46))) # Michael S. Branicky, May 04 2026
CROSSREFS
Cf. A326106 [a(n) is not divisible by any digit of a(n+1)], A326107 [a(n) is divisible by one and only one digit of a(n+1)], A326108 [a(n) is divisible by two and only two digits of a(n+1)], A326109 [a(n) is divisible by three and only three digits of a(n+1)] and A326110 [a(n) is divisible by four and only four digits of a(n+1)].
KEYWORD
base,nonn
AUTHOR
Eric Angelini and Carole Dubois, Jun 10 2019
STATUS
approved
