Fidelity Investments Interview Question

Describe an algorithm to find the first 20 prime numbers.

Interview Answer

Anonymous

Jan 24, 2014

To limit to 20 you can include a counter. Then use the sieve of Eratosthenes.

1