editing
approved
editing
approved
Project Euler, <a href="https://projecteuler.net/problem=520">Problem 520: Simbers</a>.
approved
editing
editing
approved
a(n) is the smallest integer that has exactly n simbers divisors from A333369.
15 has 4 divisors: {1, 3, 5, 15} all of which are simbers in A333369 integers; , and no positive integer smaller than 15 number has four simber divisors, this property, hence a(4) = 15.
approved
editing
reviewed
approved
proposed
reviewed
editing
proposed
(Python)
from sympy import divisors
from itertools import count, islice
def c(n): s = str(n); return all(s.count(d)%2 == int(d)%2 for d in set(s))
def f(n): return sum(1 for d in divisors(n, generator=True) if c(d))
def agen():
n, adict = 1, dict()
for k in count(1):
fk = f(k)
if fk not in adict: adict[fk] = k
while n in adict: yield adict[n]; n += 1
print(list(islice(agen(), 29))) # Michael S. Branicky, Jul 23 2022
Michael S. Branicky, <a href="/A355771/b355771.txt">Table of n, a(n) for n = 1..87</a>
approved
editing
reviewed
approved