A quick question on the modulus operator. If you look at the code everything from 3 % 3 is very clear 3/3 = 1r0 , 4/3 = r1, 5/3 =r2.
What i cannot get and i ve searched google for the answer is why 1%3 is equal to 1 when 3 fits 0 times in 1, and why is 2 % 3 equal to 2 when 2 fits 0 times in 3 as well?
echo 0 % 3 . "<br />"; // result 0
echo 1 % 3 . "<br />"; // result 1
echo 2 % 3 . "<br />"; // result 2
echo 3 % 3 . "<br />";
echo 4 % 3 . "<br />";
echo 5 % 3 . "<br />";
echo 6 % 3 . "<br />";
echo 7 % 3 . "<br />";
echo 8 % 3 . "<br />";
echo 9 % 3 . "<br />";
echo 10 % 3 . "<br />";