Question: I wrote a program to check the highest number of steps of the collatz conjecture in a range. However, the number I get is incorrect, it appears that the loop ends far too early. Can anyone tell me what is wrong with my code? I checked multiple times over different ranges and each time it is still wrong.

```
def collatz_sequence(n):
    sequence = []
    while n != 1:
        sequence.append(n)
        if n % 2 == 0:
            n = n // 2
        elif n % 2 != 0:
            n = 3 * n + 1
    return sequence

max_len = 1
for i in range(1, 1000):
    if len(collatz_sequence(i)) > max_len:
        max_len = i
        print(max_len)

```

Answer: 
According to the [API reference](https://discordpy.readthedocs.io/en/latest/api.html#discord.Status), you could use

```
if user.status != discord.Status.offline

```

PS. I know nothing about this library, yet I tried searching the docs. Give it a try from now on :)
Try this:

```py
for user in ctx.guild.members:
    if str(user.status) != "offline":
        # your code

```