+ 3
How i calculate 2%3 and 3%2
I think 3%2 =1 But 2%3=2 ?!
3 Answers
+ 5
Modulo operator returns the remainder.
So 2%3 is 2 because 2 is not divisible by 3 and 2 is the remainder.
+ 4
0%3 = 0
1%3 = 1
2%3 = 2
3%3 = 0
4%3 = 1
5%3 = 2
6%3 = 0
7%3 = 1
8%3 = 2
9%3 = 0
+ 1
modulo is pretty much
2%3 = 2 - (2 / 3)
it returns the remainder of division. i.e.
9 % 2 = 1
9 - (9 / 2) = 1
To answer your question:
3-(3/2)=1
2-(2/3)=1