"Oops, try again. Your function fails on is_prime(2). It returns False when it should return True."
It seems like it should return something. I initially didn't have 2 conditioned in (if x<2 vs if x <=2: ). Seems to work with some random prime/non-prime numbers I have tested. I'm sure it is something incredibly simple but I can't locate it for the life of me. Any pointers would be awesome
def is_prime(x): if x <= 2: return False else: for n in range(2,x): if x%n == 0: return False return True