Calculate the an % b where a, b and n are all 32bit integers.
an % b
a
b
n
For 231 % 3 = 2
231 % 3 = 2
For 1001000 % 1000 = 0
1001000 % 1000 = 0