Skip to main content
Calkulon

How to Calculate Modulo

What is Modulo?

The modulo operation finds the remainder when one number is divided by another. Written as a mod b, it's essential in number theory, cryptography, and computer science.

Formula

a mod b = remainder of a ÷ b

Step-by-Step Guide

  1. 1Divide a by b
  2. 2The remainder is the modulo result
  3. 3Result is always non-negative and less than b

Worked Examples

Input
17 mod 5
Result
2
17 = 3 × 5 + 2

Common Mistakes to Avoid

  • Confusing modulo with division
  • Incorrect remainder calculation

Ready to calculate? Try the free Modulo Calculator

Try it yourself →

Settings

PrivacyTermsAbout© 2026 Calkulon