OFFSET
1,2
COMMENTS
First positions where the numbers n=2..5 occur are at: 2, 142, 2180230, 256857823. - Vaclav Kotesovec, Apr 17 2014
PROG
(PARI)
freesqrcomp(n)=issquarefree(n)&&!isprime(n)
nextfqc(n)={local(k); k=n+1; while(!freesqrcomp(k), k+=1); return(k)}
primesin(a, b)={local(p=a, q=0); while(p<b, p=nextprime(p); if(p<b, q+=1); p+=1); return(q)}
{for(i=2, 1000, if(freesqrcomp(i), m=nextfqc(i); p=primesin(i, m); print(p)))}
CROSSREFS
KEYWORD
nonn
AUTHOR
Antonio Roldán, Apr 08 2014
STATUS
approved