How do you check if a number is prime?

Somehow implement the sieve of Eratosthene. [ O(log(log(n)) vs O(n) ] Sieve of Eratosthenes - Wikipedia