added non-recursive isPrime function to math_prac.py script