OFFSET
1,1
LINKS
Robert Israel, Table of n, a(n) for n = 1..10001
MAPLE
R:= n-> (s-> parse(cat(s[-i]$i=1..length(s))))(""||n):
q:= p-> andmap(isprime, [p, R(p)]) and ormap(
t-> andmap(isprime, [p+t, R(p+t)]), [-2, +2]):
select(q, [$2..12000])[]; # Alois P. Heinz, Jun 06 2024
PROG
(PARI) isrevp(p) = isprime(p) && isprime(fromdigits(Vecrev(digits(p))));
isok(p) = isprime(p) && ((isprime(p+2) && isrevp(p+2)) || (isprime(p-2) && isrevp(p-2))) && isrevp(p); \\ Michel Marcus, Jun 06 2024
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Thomas Otten, Jun 01 2024
STATUS
approved