Help is appreciated!
Thanks! :D/>
Uhhh 4%3 will return 1 … the math: 4 / 3 = 1 remainder 1. the only time 1/3 will be returned is if you do 3.33%3…So for example, 4%3 will return 1/3.
More precisely any time the integer components divide together into 1 (eg 5%5.33, 6%6.33).Uhhh 4%3 will return 1 … the math: 4 / 3 = 1 remainder 1. the only time 1/3 will be returned is if you do 3.33%3…So for example, 4%3 will return 1/3.
test them, they return 5 and 6, not 0.33. The left hand integer needs to be the number on the left + 0.33 … thats the only way to get a remainder of 0.33eg 5%5.33, 6%6.33
test them, they return 5 and 6, not 0.33. The left hand integer needs to be the number on the left + 0.33 … thats the only way to get a remainder of 0.33eg 5%5.33, 6%6.33
Modulo is defined as
a % b == a - math.floor(a /b )*b
That is, it is the remainder of a division that rounds the quotient towards minus infinity.
It's ok we all make mistakes from time to time (esp when we are on our phones) ;)/>Yeah my apologies. I was doing that on my phone and didn't test them or really think it through at all.
Point taken, to be fair, it was 2am at the time loltest them, they return 5 and 6, not 0.33. The left hand integer needs to be the number on the left + 0.33 … thats the only way to get a remainder of 0.33eg 5%5.33, 6%6.33