Hey all,

Technically, I’m not having any problems solving this in code (I already had). But mathematically, I’m kind of lost . I understand the concepts of **mod30** and **mod40** functions (modulo), they return either **time - (30 or 40)** or just **time** itself; depending on which interval the **time** is in:

```
def mod30(n):
if n >= 30:
return n - 30
else:
return n
```

Later in the “`while-True`

” loop the code updates the new (x, y) coordinates for next movements:

```
while True:
time = hero.time
x = mod30(time) + 25
y = mod40(time) + 10
hero.moveXY(x, y)
```

Let’s say that:

- Hero’s next position = (
**x**,**y**) - Game’s time =
**t**

When t = 0, position is (25, 10):

- x = 25
- y = 10

Let’s just put it into tracks (segments) for **x** and **y**:

- 00.0 <
**t**< 30.0 - 30.0 =<
**t**< 33.7 - 33.7 =<
**t**< 40.0 - 40.0 =<
**t**< 45.0 - 45.0 =<
**t**< 55.7

*Level: (link - location)*