OFFSET
0,2
COMMENTS
LINKS
M. F. Hasler, Table of n, a(n) for n = 0..428
PROG
(PARI) show(n, a=0, u=[a-1])={for(n=1, n, a==u[1]+1&&print1(n-1", "); u=setunion(u, [a]); while(#u>1&&u[2]==u[1]+1, u=u[^1]); for(k=u[1]+1, 9e9, !setsearch(u, k) && isprime(a*a+k) && (a=k) && break))}
CROSSREFS
KEYWORD
nonn
AUTHOR
M. F. Hasler, Feb 09 2016
STATUS
approved