A178551 Primes with exactly two 2's.
223, 227, 229, 1223, 1229, 2027, 2029, 2129, 2203, 2207, 2213, 2237, 2239, 2243, 2251, 2267, 2269, 2273, 2281, 2287, 2293, 2297, 2423, 2521, 2621, 2729, 2927, 3221, 3229, 4229, 5227, 6221, 6229, 7229, 8221, 9221, 9227, 10223, 12203, 12211, 12239, 12241, 12251, 12253
Offset: 1
Links
- Daniel Starodubtsev, Table of n, a(n) for n = 1..10000
Programs
-
Mathematica
Select[Prime[Range[1500]],Count[IntegerDigits[#],2]==2 &] (* Stefano Spezia, Aug 29 2025 *)
-
Python
from sympy import isprime print([i for i in range(10000) if str(i).count('2') == 2 and isprime(i)]) # Daniel Starodubtsev, Mar 29 2020