A386103 Primes having only {1, 2, 7, 9} as digits.
2, 7, 11, 17, 19, 29, 71, 79, 97, 127, 179, 191, 197, 199, 211, 227, 229, 271, 277, 719, 727, 797, 911, 919, 929, 971, 977, 991, 997, 1117, 1129, 1171, 1217, 1229, 1277, 1279, 1291, 1297, 1721, 1777, 1979, 1997, 1999, 2111, 2129, 2179, 2221, 2297, 2711, 2719
Offset: 1
Links
Programs
-
Magma
[p: p in PrimesUpTo(10^6) | Set(Intseq(p)) subset [1, 2, 7, 9]];
-
Mathematica
Flatten[Table[Select[FromDigits /@ Tuples[{1, 2, 7, 9}, n], PrimeQ], {n, 7}]]
-
PARI
primes_with(, 1, [1, 2, 7, 9]) \\ uses function in A385776
-
Python
print(list(islice(primes_with("1279"), 41))) # uses function/imports in A385776