Remainder Calculator
Enter two numbers to find the remainder left over after division.
Result
How it is calculated
The tool computes the remainder as r = dividend − divisor × ⌊dividend / divisor⌋, where ⌊ ⌋ rounds down to a whole number. It shows r first and the whole-number quotient second. Both inputs must be whole numbers: a decimal such as 59.5 gives no result, and so does a divisor of zero or a number beyond about 9 quadrillion (253). With positive numbers the remainder is always from 0 up to divisor − 1, and a remainder of 0 means the divisor divides the dividend evenly. Because the quotient is rounded down, the remainder takes the sign of the divisor: −3 mod 7 gives 4 with quotient −1, and 3 divided by −7 gives a remainder of −4. Many programming languages instead give −3 for −3 % 7, so the results can differ.
Worked example
Today is a given weekday; which weekday is it 59 days later? Weekdays repeat every 7 days, so divide 59 by 7. Step 1: 7 × 8 = 56, which is the largest multiple of 7 not above 59, so the quotient is 8. Step 2: 59 − 56 = 3. The tool prints a remainder of 3 and a quotient of 8. So 59 days later is the same as 3 days later: three weekdays forward.
Common mistakes
- Reading the quotient as the answer when you need the remainder. The remainder is listed first; the quotient is the number of complete groups.
- Expecting a negative remainder from a negative dividend. Here −3 ÷ 7 gives remainder 4, since the quotient rounds down to −1.
- Entering a decimal, such as 8.43 for 59 / 7, or a decimal dividend. The tool shows no result; the remainder is the leftover whole amount, 3, not the fractional part.
- Swapping dividend and divisor. 4 divided by 9 has remainder 4, but 9 divided by 4 has remainder 1.
- Comparing with a programming language and assuming a mismatch is a bug. For negative numbers many languages truncate the quotient instead of rounding it down, so the signs of the remainder differ.
About this calculator
Dividing one integer by another produces a quotient and a leftover amount, the remainder, that doesn’t divide evenly; this is the same operation programmers call the modulo (often written a % b), and it’s formally defined by the division algorithm a = b × q + r, where r is the remainder and, for positive integers, is always non-negative and smaller than b.
Programmers use the modulo operation constantly — to check whether a number is even or odd, to wrap array indices or clock values around a fixed range, to distribute items cyclically across buckets in hashing, or to control looping patterns in animations and games. Students also use remainders directly in long division, in scheduling problems, such as which day of the week falls a set number of days from today, and in basic number theory topics like divisibility rules and modular arithmetic.
Was this helpful?
You can pick up to 3 reactions.
Popular calculators
Loan Calculator
Monthly payment, total interest and full amortization schedule.
Percentage Calculator
Percent change, percent of, and ratio calculations.
Discount Calculator
Calculate final price, savings, and discount amount.
BMI Calculator
Body mass index from height and weight (metric or imperial).
Age Calculator
Compute your exact age in years, months and days from a birth date.
Compound Interest Calculator
Calculate the final amount and interest earned with compounding.
All Calculators
- Loan Calculator
- Profit Calculator
- Discount Calculator
- BMI Calculator
- Percentage Calculator
- Ideal Weight Calculator
- Age Calculator
- Pregnancy Due Date Calculator
- Compound Interest Calculator
- BMR Calculator (Basal Metabolic Rate)
- Tip Calculator
- Fuel Cost Calculator
- Date Difference Calculator
- Sleep Cycle Calculator
- Daily Water Intake Calculator
- Simple Interest Calculator
- Heart Rate Zones Calculator
- Running Pace Calculator
- Pet Age Calculator
- Calories Burned Calculator
- Macro Calculator
- TDEE Calculator (Total Daily Energy Expenditure)
- Waist-to-Hip Ratio Calculator
- Honor Roll Calculator
- One Rep Max (1RM) Calculator
- Ovulation Calculator
- Electricity Cost Calculator
- Unit Price Calculator
- Savings Goal Calculator
- Break-Even Point Calculator
- Paint Calculator
- Course Grade Average Calculator
- Business Days Calculator
- Time Duration Calculator
- Fuel Economy Calculator
- Temperature Converter
- Tile Calculator
- Aspect Ratio Calculator
- Roman Numeral Converter
- Goal Weight Timeline Calculator
- Salary Converter (Hourly to Annual)
- Credit Card Validator (Luhn)
- Body Surface Area (BSA) Calculator
- Feels-Like Temperature Calculator
- Ohm’s Law Calculator
- PPI (Pixel Density) Calculator
- Molar Mass Calculator
- Zodiac Sign Calculator (Western + Chinese)
- IBAN Validator
- Shoe Size Converter
- Country Info & Dialing Code Lookup
- Time Zone Difference (World Clock)
- CAGR (Compound Annual Growth Rate) Calculator
- Rule of 72 Calculator
- Blood Alcohol Content (BAC) Calculator
- Lean Body Mass (LBM) Calculator
- Pythagorean Theorem Calculator
- Speed Converter
- Download Time Calculator
- Date Calculator (Add/Subtract)
No calculators found
Comments