I am stuck on the problem is_prime.

Below is what I have and it throughs the error:

Your function fails on is_prime(3). It returns None when it should return True.

I am confused as to why this is. It seems to me that because it doesn't qualify in line 8, it should return True in the las line.

Could someone help me out?

```
def is_prime(x):
if x == 0 or x == 1:
return False
elif x == 2:
return True
else:
for n in range(2, x-1):
if x % n == 0:
return False
else:
return True
```