We are about to switch to a new forum software. Until then we have removed the registration on this forum.
Modulus is broken in this way:
-1 % 192. Should be 191, right? In processing 3, the answer is -1. I need a workaround or something, as I cannot continue doing what I am doing with this bug,
Answers
0
.-1
.-1 % 192
.-1
in JavaScript as well. :>https://www.google.co.uk/search?q=-1+%+192&oq=-1+%+192&aqs=chrome..69i57.6294j0j7&sourceid=chrome&ie=UTF-8
I would like to mimic this behavior. Any way?
(i + n) % n
(Assuming i never gets below -n...)
so is this mimicing i % n? or am i mistaken?
((i % n) + n) % n
If I does go below -n
lol refresh XD
oh its i % n... thanks! this helps greatly
Oh, you were asking for a backwards modulo calc. #-o
already solved.. but thanks for the help anyway!