OFFSET
0,2
PROG
(PARI) a(n) = #Set(Vec(prod(k=1, n, 1+x^prime(k))));
(Python)
from collections import Counter
from sympy import prime
def A369788(n):
c = {0:1}
for k in range(1, n+1):
m, d = prime(k), Counter(c)
for j in c:
d[j+m] += c[j]
c = d
return len(set(c.values()))+int(max(c)+1>len(c)) # Chai Wah Wu, Feb 01 2024
CROSSREFS
KEYWORD
nonn
AUTHOR
Seiichi Manyama, Feb 01 2024
STATUS
approved