Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
A097312
Numbers with property that can bring the first digit to the back of the number to get a prime (zeros are dropped).
2
2, 3, 5, 7, 11, 13, 14, 16, 17, 20, 30, 31, 32, 34, 35, 37, 38, 50, 70, 71, 73, 74, 76, 79, 91, 92, 95, 97, 98, 101, 103, 104, 106, 107, 110, 113, 115, 118, 119, 121, 124, 125, 127, 128, 131, 133, 140, 142, 143, 146, 149, 152, 154, 157, 160, 163, 164, 166, 169, 170
OFFSET
1,1
COMMENTS
First differs from A095179 at a(31) = 103 since A095179(31) = 104 because 401 is prime but 301 = 7 * 43. - Alonso del Arte, Apr 12 2020
LINKS
Michael S. Branicky, Table of n, a(n) for n = 1..11018 (all terms < 10**5)
EXAMPLE
1234 is in the sequence because 2341 is prime.
MATHEMATICA
Select[Range[200], PrimeQ[FromDigits[RotateLeft[IntegerDigits[#]]]] &] (* Harvey P. Dale, Jun 06 2018 *)
PROG
(Python)
from sympy import isprime
def ok(n): s = str(n); return isprime(int(s[1:]+s[0]))
print([k for k in range(171) if ok(k)]) # Michael S. Branicky, May 08 2023
CROSSREFS
Sequence in context: A275721 A007933 A032524 * A095179 A074895 A371653
KEYWORD
base,easy,nonn
AUTHOR
Jason Earls, Mar 16 2005
STATUS
approved