A386123 Primes having only {1, 4, 6, 7} as digits.
7, 11, 17, 41, 47, 61, 67, 71, 167, 461, 467, 617, 641, 647, 661, 677, 761, 1117, 1171, 1447, 1471, 1667, 1741, 1747, 1777, 4111, 4177, 4441, 4447, 6661, 6761, 7177, 7411, 7417, 7477, 7717, 7741, 11117, 11161, 11171, 11177, 11411, 11447, 11467, 11471, 11617, 11677
Offset: 1
Links
Programs
-
Magma
[p: p in PrimesUpTo(10^6) | Set(Intseq(p)) subset [1, 4, 6, 7]];
-
Mathematica
Flatten[Table[Select[FromDigits /@ Tuples[{1, 4, 6, 7}, n], PrimeQ], {n, 7}]]
-
PARI
primes_with(, 1, [1, 4, 6, 7]) \\ uses function in A385776
-
Python
print(list(islice(primes_with("1467"), 41))) # uses function/imports in A385776