Time Complexity: Primality

  • + 1 comment

    Hi. I'm surprised it timed out for you. Here's my attempt at coding the Sieve of Eratosthenes functions. I made some optimizations that may be useful for your code. (The code is general and is from a problem from "cracking the coding interview")

    HackerRank solutions.