OFFSET
1,2
LINKS
T. D. Noe, Table of n, a(n) for n = 1..1000
PROG
(PARI) a(n)=v=[1]; k=1; while(#v<=n, if(isprime(k+v[#v])&&!vecsearch(vecsort(v), k), v=concat(v, k); k=0); k++); v[#v-1]
n=1; while(n<1000, if(a(n)==n, print1(n, ", ")); n++) \\ Derek Orr, Jun 08 2015
CROSSREFS
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, Apr 03 2006
STATUS
approved