Modulo Operator Calculator

Your details

Each mode pre-fills sensible defaults and shows the relevant practical interpretation.
Conventions differ for negative inputs. For positive numbers all three agree. Euclidean is the most mathematically standard.
The number being divided.
The number dividing the dividend. Cannot be zero.
Remainder (a mod n)Remainder: 2
2

The remainder after dividing the dividend by the divisor.

Quotient3
Verification3 x 5 + 2 = 17
Interpretation17 divided by 5 leaves a remainder of 2.
Remainder2
Quotient3

17 mod 5 = 2

  • The remainder 2 satisfies a = q x n + r, so 17 = 3 x 5 + 2.
  • Because the remainder is non-zero, 5 does not divide 17 exactly.
  • The remainder is always between 0 (inclusive) and |n| (exclusive) for Euclidean convention.

Next stepTry the Divisibility check or Odd/Even mode for a targeted practical use case.

= Powered by OnlyCalculators