login
A243531
Prime numbers containing the string 15.
2
151, 157, 1151, 1153, 1511, 1523, 1531, 1543, 1549, 1553, 1559, 1567, 1571, 1579, 1583, 1597, 2153, 4153, 4157, 4159, 5153, 6151, 7151, 7159, 9151, 9157, 10151, 10159, 11159, 11503, 11519, 11527, 11549, 11551, 11579, 11587, 11593, 11597, 12157, 13151, 13159
OFFSET
1,1
LINKS
FORMULA
a(n) ~ n log n. - Charles R Greathouse IV, Jun 20 2014
MATHEMATICA
Select[Prime[Range[2000]], !StringFreeQ[ToString[#], "15" ] &]
Select[Prime[Range[2000]], SequenceCount[IntegerDigits[#], {1, 5}]>0&] (* Harvey P. Dale, Sep 19 2023 *)
PROG
(PARI) contains(n, k)=my(N=digits(n), K=digits(k)); for(i=0, #N-#K, for(j=1, #K, if(N[i+j]!=K[j], next(2))); return(1)); 0
is(n)=isprime(n) && contains(n, 15) \\ Charles R Greathouse IV, Jun 20 2014
CROSSREFS
Cf. similar sequences listed in A243529.
Sequence in context: A336777 A250312 A180554 * A139505 A095745 A112796
KEYWORD
nonn,base,less
AUTHOR
Vincenzo Librandi, Jun 06 2014
STATUS
approved