Find the nth prime
Return the nth prime number. Start with trial division, then use a sieve of Eratosthenes with an estimated upper bound and explain the complexity of both.
No answer yet. Write the first one; the best answer gets endorsed.
Return the nth prime number. Start with trial division, then use a sieve of Eratosthenes with an estimated upper bound and explain the complexity of both.