I’m getting stuck on an infinite loop when I try this:

```
def is_prime(x):
if x < 2:
return False
elif x == 2:
return True
else:
n = 2
while n < x:
if x % n == 0:
return False
else:
n += 1
return True
```

Which doesn’t make sense to me. Any suggestions? Thank you``