added opt to isPrime
opted isPrime from euler7