|
|
A257668
|
|
Primes containing a digit 7.
|
|
6
|
|
|
7, 17, 37, 47, 67, 71, 73, 79, 97, 107, 127, 137, 157, 167, 173, 179, 197, 227, 257, 271, 277, 307, 317, 337, 347, 367, 373, 379, 397, 457, 467, 479, 487, 547, 557, 571, 577, 587, 607, 617, 647, 673, 677, 701, 709, 719, 727, 733, 739, 743, 751, 757, 761
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,1
|
|
COMMENTS
|
|
|
LINKS
|
|
|
FORMULA
|
|
|
EXAMPLE
|
For n = 2, a(2) = 17 is the second prime containing a digit of 7.
|
|
MATHEMATICA
|
Select[Prime[Range[150]], ! StringFreeQ[ToString[#], "7"] &]
|
|
PROG
|
(Magma) [p: p in PrimesUpTo(800) | 7 in Intseq(p)];
(Sage) [p for p in primes(800) if 7 in p.digits(base=10)] # Bruno Berselli, May 03 2015
(PARI) lista(nn) = forprime(p=2, nn, if(vecsearch(vecsort(digits(p)), 7), print1(p, ", "))); \\ Altug Alkan, Apr 21 2016; corrected by Michel Marcus, Oct 30 2023
|
|
CROSSREFS
|
Cf. similar sequences listed in A257667.
|
|
KEYWORD
|
nonn,base,easy
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|