Now as to why 9 is being evaluated as prime, peppering your code with debug statements like so:

```
def is_prime(x) :
if x < 2 :
return False
elif x == 3 or x == 2:
return "Should catch only 2 and 3"
else:
for i in range(2, x):
print " %s %% %s = %s" % (x, i, x % i)
if x % i == 0 :
return False
else:
return True
for i in range(10):
print "%s is prime? %s" % (i, is_prime(i))
```

will yield:

```
0 is prime? False
1 is prime? False
2 is prime? Should catch only 2 and 3
3 is prime? Should catch only 2 and 3
4 % 2 = 0
4 is prime? False
5 % 2 = 1
5 is prime? True
6 % 2 = 0
6 is prime? False
7 % 2 = 1
7 is prime? True
8 % 2 = 0
8 is prime? False
9 % 2 = 1
9 is prime? True
```

Can you spot the problem now?

You are exiting your `for`

loop and returning `True`

after evaluating only one value. You need to indent your `else`

back one level like so:

```
def is_prime(x) :
if x < 2 :
return False
elif x == 3 or x == 2:
return "Should catch only 2 and 3"
else:
for i in range(2, x):
print " %s %% %s = %s" % (x, i, x % i)
if x % i == 0 :
return False
# now, if your condition is not met, it will continue to loop!
# and at this point, when the for loop is over, if it has not returned
# anything as False, it will then resort to this else which will return True
else:
return True
for i in range(10):
print "%s is prime? %s" % (i, is_prime(i))
```

and now it will yield the expected result:

```
0 is prime? False
1 is prime? False
2 is prime? Should catch only 2 and 3
3 is prime? Should catch only 2 and 3
4 % 2 = 0
4 is prime? False
5 % 2 = 1
5 % 3 = 2
5 % 4 = 1
5 is prime? True
6 % 2 = 0
6 is prime? False
7 % 2 = 1
7 % 3 = 1
7 % 4 = 3
7 % 5 = 2
7 % 6 = 1
7 is prime? True
8 % 2 = 0
8 is prime? False
9 % 2 = 1
9 % 3 = 0
9 is prime? False
```

Hope this helped!