A386188 Primes having only {4, 5, 6, 7} as digits.
5, 7, 47, 67, 457, 467, 547, 557, 577, 647, 677, 757, 4447, 4457, 4547, 4567, 4657, 5477, 5557, 5647, 5657, 6547, 6577, 7457, 7477, 7547, 7577, 7757, 44647, 44657, 44777, 45557, 45667, 45677, 45757, 45767, 46447, 46457, 46477, 46567, 46747, 46757, 47657, 47777
Offset: 1
Links
Programs
-
Magma
[p: p in PrimesUpTo(10^6) | Set(Intseq(p)) subset [4, 5, 6, 7]];
-
Mathematica
Flatten[Table[Select[FromDigits /@ Tuples[{4, 5, 6, 7}, n], PrimeQ], {n, 7}]]
-
PARI
primes_with(, 1, [4, 5, 6, 7]) \\ uses function in A385776
-
Python
print(list(islice(primes_with("4567"), 41))) # uses function/imports in A385776