Time Complexity: Primality | HackerRank
Determine whether or not a number is prime in optimal time.