OFFSET
1,1
LINKS
Michael S. Branicky, Table of n, a(n) for n = 1..10000
PROG
(Python)
from sympy import prime
from itertools import count, islice
def a(n):
return int("".join(map(str, range(1 if n<2 else prime(n-1)+1, prime(n)+1))))
print([a(n) for n in range(1, 31)]) # Michael S. Branicky, Nov 18 2023
(Python) # faster for generating initial segment of sequence
from sympy import isprime
from itertools import count, islice
def agen():
cat = ""
for i in count(1):
cat += str(i)
if isprime(i): yield int(cat); cat = ""
print(list(islice(agen(), 30))) # Michael S. Branicky, Nov 18 2023
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Tamas Sandor Nagy, Nov 18 2023
STATUS
approved