added an isPrime check to 003.py