OFFSET
1,1
LINKS
M. F. Hasler, Table of n, a(n) for n = 1..655
EXAMPLE
The first digit, 2, is prime, so a(1) = 2.
The second digit, 7, is prime, so a(2) = 7. 27 is not prime.
The third digit, 1, is not prime, but 71 and 271 are, so a(3) = 71 and a(4) = 271.
a(17) shows that "leading zeros are not allowed", i.e., if a prime p is prefixed by a 0 then it is not listed twice. - M. F. Hasler, Feb 05 2012
PROG
(PARI) v=[2, 7, 1, 8, 2, 8, 1, 8, 2, 8, 4, 5, 9, 0, 4, 5, 2, 3, 5, 3, 6, 0, 2, 8, 7, 4, 7, 1, 3]
for(n=1, #v, x=0; p=1; forstep(k=n, 1, -1, x+=p*v[k]; p*=10; if(v[k]&&isprime(x), print1(x", "))))
(PARI) default(realprecision, D=300); for(i=0, D-5, E=exp(1)\.1^i; for(j=1, i+1, ispseudoprime(t=E%10^j) & t!=L print1(L=t", "))) \\ M. F. Hasler, Feb 05 2012
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Franklin T. Adams-Watters, Oct 21 2011
STATUS
approved