A321523 List of pairs: primes whose reversal is also prime, each followed by its reversal.
2, 2, 3, 3, 5, 5, 7, 7, 11, 11, 13, 31, 17, 71, 31, 13, 37, 73, 71, 17, 73, 37, 79, 97, 97, 79, 101, 101, 107, 701, 113, 311, 131, 131, 149, 941, 151, 151, 157, 751, 167, 761, 179, 971, 181, 181, 191, 191, 199, 991, 311, 113, 313, 313, 337, 733, 347, 743, 353, 353
Offset: 1
Examples
The sequence begins: 2, 2; 3, 3; 5, 5; 7, 7; 11, 11; 13, 31; 17, 71; 31, 13; 37, 73; 71, 17; ... 107 has its reversal as 701. 971 has its reversal as 179.
Programs
-
Mathematica
Flatten@ Table[ If[PrimeQ[r = IntegerReverse@ p], {p,r}, {}], {p, Prime@ Range@ 71}] (* Giovanni Resta, Nov 13 2018 *)
-
PARI
forprime(p=1, 353, r=fromdigits(Vecrev(digits(p))); if (isprime(r), print1(p ", " r ", "))) \\ Rémy Sigrist, Nov 16 2018