Hello!

I have a problem with one of the Python tutorial. I wrote a programme for checking if a number is prime or not. I used a range from 2 to x - 1, where x is the read number and it tells me that I have an error. Could somebody please tell me what I am doing wrong? Here is the code:

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

Thank you!