What purpose does modulo serve?


Hello everyone,

sorry for posting 2 topics in one day, but I am at a complete loss.

I’m in the middle of Zig, Zag, and Zoom which uses a modulo operation. I just don’t get what we use it for in that level and the one before it. like, why use that instead of adding or subtracting from the x and y position? I just really don’t get modulo at all.


please show us your code.


it’s just a mathematical formula where a remainder is derived and you base your code on the existence or lack of that remainder.