OFFSET
1,7
COMMENTS
a(A045546(n)) = 1.
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
FORMULA
MAPLE
0, seq(n^2 + n - prevprime(n^2+n), n=2..100); # Robert Israel, Jul 03 2017
MATHEMATICA
Table[k = 0; While[! PrimeQ[n^2 + n - k], k++]; k, {n, 85}] (* Michael De Vlieger, Jul 04 2017 *)
PROG
(PARI) for(n=1, 85, k={my(k=0); while(!isprime(n^2+n-k), k++); k; }; print1(k", "))
CROSSREFS
KEYWORD
nonn
AUTHOR
Gionata Neri, Jul 03 2017
STATUS
approved