Module 3.5 · Number Theory
Remainders
"What is the remainder when is divided by ?" The number has digits, but you never need to compute it. Remainders follow simple arithmetic rules of their own, so you can throw away everything except the remainders and work with small numbers the whole time.
The basic rules
When you divide by , you get a quotient and a remainder with and . For example, , so leaves remainder when divided by .
Replace numbers by their remainders
When you add, subtract or multiply whole numbers, the remainder of the result (on division by ) depends only on the remainders of the numbers you started with. So you may replace any number by its remainder at any step.
Why it works. Say and . Then Every term except is a multiple of , so has the same remainder as , namely . Sums work the same way.
Many contest writers use the notation (" is congruent to mod ") to mean and leave the same remainder when divided by . For example, .
Worked example: A big product
What is the remainder when is divided by ?
A number and its digit sum leave the same remainder on division by . has digit sum , remainder . has digit sum , remainder . So the product leaves remainder .
Powers: look for a 1
To find the remainder of a huge power, compute small powers until the remainder is . After that, the pattern repeats.
Worked example: A huge power
What is the remainder when is divided by ?
Remainders of divided by : . So leaves remainder . Since , which has the same remainder as . And , so the remainder is 4.
Tip
Days of the week are remainders on division by . A date days from a Saturday is days later, so it falls days after Saturday: Monday. And because , a date moves forward one weekday each ordinary year.
Several conditions at once
Worked example: One less than a multiple
What is the smallest positive integer that leaves remainder when divided by , remainder when divided by , and remainder when divided by ?
Each remainder is one less than the divisor. So is divisible by , and , meaning is a multiple of . The smallest is , so .
When there's no such pattern, list the numbers that satisfy the condition with the largest divisor and test them against the others.
Worked example: Listing
Find the smallest positive integer that leaves remainder when divided by and remainder when divided by .
Numbers with remainder mod : Their remainders mod : . So the answer is . (All solutions are .)
Common mistake
A remainder can never be negative or as large as the divisor. If your work gives when dividing by , add to get the true remainder, .
Practice
What is the remainder when is divided by ?
Enter a number. Fractions like 3/4 and sqrt(2) are OK.
What is the remainder when is divided by ?
Enter a number. Fractions like 3/4 and sqrt(2) are OK.
What is the remainder when is divided by ?
Enter a number. Fractions like 3/4 and sqrt(2) are OK.
A whole number leaves remainder when divided by . What is the remainder when is divided by ?
Enter a number. Fractions like 3/4 and sqrt(2) are OK.
Today is Saturday. What day of the week will it be days from today?
What is the remainder when is divided by ?
Enter a number. Fractions like 3/4 and sqrt(2) are OK.
What is the smallest positive integer that leaves remainder when divided by , remainder when divided by , and remainder when divided by ?
Enter a number. Fractions like 3/4 and sqrt(2) are OK.
What is the remainder when is divided by ?
Enter a number. Fractions like 3/4 and sqrt(2) are OK.
What is the remainder when is divided by ?
Enter a number. Fractions like 3/4 and sqrt(2) are OK.
Real contest practice
- 2016 AMC 8, Problem 5: a two-digit number described by its remainders.
- 2018 AMC 8, Problem 21: three-digit numbers with three remainder conditions.