login
A392156
a(n) is the number of distinct primes obtainable by inserting exactly one decimal digit into the decimal representation of prime(n) (at any position, including before the first digit or after the last), with the resulting number required to have no leading zero.
2
2, 8, 2, 8, 10, 10, 10, 12, 8, 6, 7, 10, 10, 7, 8, 8, 7, 10, 9, 7, 7, 8, 9, 5, 10, 15, 10, 6, 15, 12, 11, 12, 9, 5, 11, 10, 7, 8, 12, 9, 10, 10, 8, 10, 11, 10, 12, 9, 10, 12, 8, 10, 8, 8, 9, 8, 10, 12, 10, 9, 11, 10, 9, 11, 5, 9, 10, 10, 9, 8, 8, 8, 14, 8, 9, 8
OFFSET
1,1
EXAMPLE
The a(10) = 6 primes obtainable from prime(10) = 29 are 229, 239, 269, 293, 829 and 929.
MAPLE
A392156 := proc(n) local i, j, k, l, p; p := ListTools:-Reverse(convert(ithprime(n), 'base', 10)); k := nops(p); l := []; for i from 0 to 9 do for j from 0 to k do if i + j > 0 then l := [op(l), [op(p[1 .. j]), i, op(p[j + 1 .. k])]]; end if; end do; end do; nops(convert(select(isprime, {op(map(z -> foldl((x, y) -> 10*x + y, 0, op(z)), l))}), set)); end proc: seq(A392156(n), n = 1 .. 76);
PROG
(Python)
from sympy import isprime, prime
def a(n):
s = str(prime(n))
return len(set(p for i in range(len(s)+1) for d in "0123456789"[int(i==0):] if isprime(p:=int(s[:i]+d+s[i:]))))
print([a(n) for n in range(1, 77)]) # Michael S. Branicky, Jan 25 2026
KEYWORD
nonn,base
AUTHOR
Felix Huber, Jan 20 2026
STATUS
approved