Building the fastest algorithm to find if a given number is a prime