Sieve of Eratosthenes

In this lesson, we'll see an efficient algorithm to generate prime numbers.

We'll cover the following...

Generating primes

Given an integer NN, you are asked to print all the prime numbers between 11 and NN.

Using what we have discussed so far, one way to do this would be to iterate over all the numbers from 11 to NN and check if it’s prime or not.

Time Complexity - O ...

Access this course and 1400+ top-rated courses and projects.