check if a number is prime or not with do