OFFSET
1,1
EXAMPLE
a(1)=5 because between s(1)=4 and s(2)=6 there is one prime 5,
a(2)=7 because between s(2)=6 and s(3)=9 there is one prime 7,
a(3)=0 because between s(3)=9 and s(4)=10 there is no primes;
a(4)=24 because between s(4)=10 and s(5)=14 there are two primes 11 and 13 sum of which is 24, (s(n)=n-th semiprime).
MATHEMATICA
With[{sps=Partition[Select[Range[250], PrimeOmega[#]==2&], 2, 1]}, Total[ Select[ Range[ First[#], Last[#]], PrimeQ]]&/@sps] (* Harvey P. Dale, Sep 04 2011 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Zak Seidov, Dec 22 2007
STATUS
approved