Java has one important arithmetical operator you may not be familiar with, %, also known as the modulus operator.The modulus operator,
As shown above, when we divide
x mod 10 = 2
When 32 is divided by 10, the quotient will be 3 and the modulus (or remainder) will be 2. Similarly when 36.75 is divided by 10, the quotient will again be 3, where as the modulus will be 6.75.