A386240 Primes containing the digit string "007" in their decimal representation.
4007, 6007, 9007, 10007, 10079, 12007, 13007, 16007, 20071, 24007, 30071, 36007, 45007, 50077, 60077, 61007, 64007, 70079, 78007, 80071, 80077, 82007, 88007, 90007, 90071, 90073, 94007, 97007, 100703, 100733, 100741, 100747, 100769, 100787, 100799, 103007, 108007
Offset: 1
Links
- Alois P. Heinz, Table of n, a(n) for n = 1..36628
- Karl-Heinz Hofmann, Ascii search picture. Who can find the first 5 terms?
- Q-branch staff, The origin of James Bond: unveiling the history behind 007, 21 February 2024.
- Reddit, We never saw Daniel Craig's Bond in his prime
- Joe Roberts, How James Bond Became 007 (& How Its Meaning Has Changed), Jul 7, 2020.
- Joe Roberts, How Did James Bond Get The Codename 007? A Canceled Movie Almost Gave Us The Answer, Feb 24, 2025.
Programs
-
Maple
q:= n-> isprime(n) and searchtext("007", ""||n)>0: select(q, [$1..110000])[]; # Alois P. Heinz, Jul 17 2025
-
Mathematica
Select[Prime[Range[553, 12000]], StringContainsQ[IntegerString[#], "007"] &] (* Paolo Xausa, Jul 17 2025 *)
-
PARI
is(n) = if(!isprime(n), return(0)); while(n > 10, if(n%1000==7, return(1)); n\=10); 0 \\ David A. Corneth, Jul 17 2025
-
Python
from sympy import sieve print([sieve[n] for n in range(1,10200) if "007" in str(sieve[n])]) # Karl-Heinz Hofmann, Jul 17 2025
Comments