PrimeCheck function

Checks if a integer up to 1,000,000 is prime.