A386037 Primes having only {0, 1, 6, 9} as digits.
11, 19, 61, 101, 109, 191, 199, 601, 619, 661, 691, 911, 919, 991, 1009, 1019, 1061, 1069, 1091, 1109, 1601, 1609, 1619, 1669, 1699, 1901, 1999, 6011, 6091, 6101, 6199, 6619, 6661, 6691, 6911, 6961, 6991, 9001, 9011, 9091, 9109, 9161, 9199, 9601, 9619, 9661, 9901
Offset: 1
Links
Programs
-
Magma
[p: p in PrimesUpTo(10^6) | Set(Intseq(p)) subset [0, 1, 6, 9]];
-
Maple
f:= n-> (l-> add([0, 1, 6, 9][l[j]+1]*10^(j-1), j=1..nops(l)))(convert(n, base, 4)): select(isprime, [seq(f(i), i=0..250)])[]; # Alois P. Heinz, Jul 15 2025
-
Mathematica
Select[FromDigits /@ Tuples[{0, 1, 6, 9}, n], PrimeQ]
-
PARI
primes_with(, 1, [0, 1, 6, 9]) \\ uses function in A385776
-
Python
print(list(islice(primes_with("0169"), 41))) # uses function/imports in A385776