This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A069706 #13 Nov 12 2015 01:58:13 %S A069706 2,3,5,7,11,13,17,31,37,71,73,79,97,101,107,113,131,149,151,157,167, %T A069706 179,181,191,199,311,313,337,347,353,359,373,383,389,701,709,727,733, %U A069706 739,743,751,757,761,769,787,797,907,919,929,937,941,953,967,971,983,991,1009,1013 %N A069706 Primes with property that swapping first and last digits also gives a prime. %C A069706 This is not the same as A007500, "palindromic" primes. %H A069706 Chai Wah Wu, <a href="/A069706/b069706.txt">Table of n, a(n) for n = 1..10000</a> %e A069706 1049 and 9041 both are primes hence both are members. %p A069706 swapdigs:= proc(n) local d; %p A069706 d:= ilog10(n); %p A069706 n + ((n mod 10)-floor(n/10^d))*(10^d-1); %p A069706 end proc: %p A069706 select(isprime and isprime @ swapdigs, [2,seq(2*i+1,i=1..10^4)]); # _Robert Israel_, Nov 11 2015 %t A069706 Do[t = IntegerDigits[ Prime[n]]; u = t; u[[1]] = t[[ -1]]; u[[ -1]] = t[[1]]; t = FromDigits[u]; If[ PrimeQ[t], Print[ Prime[n]]], {n, 1, 300}] %o A069706 (Python) %o A069706 from sympy import prime, isprime %o A069706 A069706_list = [2,3,5,7] %o A069706 for i in range(5,10**6): %o A069706 p = prime(i) %o A069706 s = str(p) %o A069706 if isprime(int(s[-1]+s[1:-1]+s[0])): %o A069706 A069706_list.append(p) # _Chai Wah Wu_, Nov 11 2015 %Y A069706 Cf. A007500, A069707, A069708. %K A069706 nonn,base %O A069706 1,1 %A A069706 _Amarnath Murthy_, Apr 08 2002 %E A069706 Edited and extended by _Robert G. Wilson v_, Apr 12 2002 %E A069706 Edited by _N. J. A. Sloane_, Jan 20 2009