OFFSET
1,1
LINKS
Pierre CAMI, Table of n, a(n) for n = 1..125
MATHEMATICA
a[n_] := Block[{p=7(10^Prime[n]-1)/9-1}, While[{} != Intersection[ IntegerDigits@p, {0, 1, 4, 6, 8, 9}], p = NextPrime[p, -1]]; p]; Array[a, 13] (* Giovanni Resta, May 06 2016 *)
PROG
(PARI) isok(n) = {if (isprime(n), vd = vecsort(digits(n), , 8); for (i=1, #vd, if (!isprime(vd[i]), return (0))); return (1); ); }
a(n) = {gp = 7*(10^prime(n)-1)/9; while (!isok(gp), gp = precprime(gp-2)); gp; } \\ Michel Marcus, May 06 2016
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Pierre CAMI, May 06 2016
EXTENSIONS
More terms from Michel Marcus, May 06 2016
a(57) in the b-file corrected by Giovanni Resta, May 06 2016
STATUS
approved