remove extraneous space
make primes slightly more efficient by guarding
problem 7