0,2

Table of n, a(n) for n=0..104.

a(n)=A101264(n), n>1. [From R. J. Mathar, Dec 13 2008]

a(1)=2 because between 2 and 4 there are two primes: 2,3;

a(2)=1 because between 4 and 6 there is one prime: 5;

a(4)=0 because between 8 and 10 there are no primes.

(PARI) a(n) = if (n==0, 1, if (n==1, 2, isprime(2*n+1))) \\ Michel Marcus, Jun 03 2013

Sequence in context: A133699 A157361 A224444 * A145865 A076452 A076453

Adjacent sequences: A101805 A101806 A101807 * A101809 A101810 A101811

easy,nonn

Giovanni Teofilatto, Jan 27 2005

approved