A386094 Primes having only {1, 2, 4, 9} as digits.
2, 11, 19, 29, 41, 149, 191, 199, 211, 229, 241, 419, 421, 449, 491, 499, 911, 919, 929, 941, 991, 1129, 1229, 1249, 1291, 1429, 1499, 1949, 1999, 2111, 2129, 2141, 2221, 2411, 2441, 2999, 4111, 4129, 4211, 4219, 4229, 4241, 4421, 4441, 4919, 4999, 9199, 9221
Offset: 1
Links
Programs
-
Magma
[p: p in PrimesUpTo(10^6) | Set(Intseq(p)) subset [1, 2, 4, 9]];
-
Mathematica
Flatten[Table[Select[FromDigits /@ Tuples[{1, 2, 4, 9}, n], PrimeQ], {n, 7}]]
-
PARI
primes_with(, 1, [1, 2, 4, 9]) \\ uses function in A385776
-
Python
print(list(islice(primes_with("1249"), 41))) # uses function/imports in A385776