Counting prime numbers smaller than n.

Revision en1, by Funfunfunfun, 2020-12-31 09:39:34

The other day I met a problem that needed to count the number of primes less than n with n <= 1e10. But I only know how to use sieve to solve but it can only run with n <= 1e6. Can you help me find a better solution? thanks for help!

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en1 English Funfunfunfun 2020-12-31 09:39:34 272 Initial revision (published)