Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.
%I #11 Aug 22 2019 09:39:32
%S 0,0,1,2,4,4,6,6,8,10,10,13,15,15,16,18,21,21,23,24,24,26,27,30,34,34,
%T 34,35,35,36,42,43,45,45,50,50,51,54,55,56,58,58,61,61,62,62,68,75,76,
%U 76,76,78,78,80,82,84,86,86,87,88,88,91,98,99,99,100,106,108,111,111
%N Number of semiprimes smaller than the n-th prime.
%H M. F. Hasler, <a href="/A111457/b111457.txt">Table of n, a(n) for n = 1..9592</a>
%t s = Select[Range@1000, Plus @@ Last /@ FactorInteger@ # == 2 &]; Table[ Length@Select[s, # < Prime@n &], {n, 70}] (* _Robert G. Wilson v_ *)
%t Module[{nn=500,sp},sp=Table[If[PrimeOmega[n]==2,1,0],{n,nn}];Table[ Total[ Take[sp,p]],{p,Prime[Range[PrimePi[nn]]]}]] (* _Harvey P. Dale_, Aug 22 2019 *)
%o (PARI) n=c=0;forprime(p=1,999,while(n<p,bigomega(n++)==2&&c++);print1(c",")) \\ _M. F. Hasler_, Jan 02 2015
%Y Cf. A001358, A000040.
%K nonn
%O 1,4
%A _Giovanni Teofilatto_, Nov 15 2005
%E More terms from _Robert G. Wilson v_ and _Stefan Steinerberger_, Nov 18 2005
%E Title edited by _M. F. Hasler_, Jan 02 2015