HI, You've given a solution for is_prime but I can't get it out from the error.Please can you help me.
Please make your own topic with code + question + error message, the response times on the forums are good, someone will help you
def is_prime(x): for n in range(2 , x-1): if x % n == 0: return False else: return True
The error is:Oops, try again.
Your function fails on is_prime(0). It returns None when it should return False.
I am not going to answer that, i already did:
2 is bigger then -1, so the loop won't run