Exercises — Modular arithmetic — definition, addition, multiplication, congruence
This is the practice deck for the parent topic. Work each problem before opening its solution. The problems climb five levels: L1 Recognition (can you spot it?), L2 Application (can you run the rule?), L3 Analysis (can you break it apart?), L4 Synthesis (can you combine ideas?), L5 Mastery (can you invent the route?).
Everything here uses only three ideas from the parent note, so let's re-anchor them in one breath before we start.
Whenever we say "reduce " we mean: divide by , throw away the quotient, keep the remainder. That remainder is guaranteed to sit in — this is exactly the Division Algorithm.

Level 1 — Recognition
Exercise 1.1
Is ? Answer yes/no and say why.
Recall Solution 1.1
What we do: check whether the difference is a multiple of — that is the raw definition. What it looks like: on a -hour clock, starting at and walking steps means walking exactly full laps, landing back on the same mark as . Since is a multiple of , yes, . ✓ (Cross-check with remainders: and — both remainder .)
Exercise 1.2
Which of these are congruent to ?
Recall Solution 1.2
What we do: reduce each number mod and keep the ones whose remainder is .
- ✓
- ✓
- ✗
- : add to climb into range, ✓
- ✓
Congruent to : . The odd one out is .
Exercise 1.3
Find the standard-form value of (an answer in ).
Recall Solution 1.3
Why we can't stop at : standard form must land in , and is negative — it points behind zero on the clock. We add laps of until we're inside the range. What it looks like: three forward laps of ( total) undo the negative and drop us on mark . Answer: . ✓ (Check: .)
Level 2 — Application
Exercise 2.1
Compute using reduce-then-add.
Recall Solution 2.1
Why reduce first: the addition rule lets us swap each number for its remainder before adding, keeping numbers small.
Add the small ones: , which already lies in . Answer: . ✓ (Direct check: .)
Exercise 2.2
Compute .
Recall Solution 2.2
Reduce each factor (multiplication rule):
Multiply the small ones: . Now is bigger than , so reduce once more: Answer: . ✓ (Direct: .)
Exercise 2.3
Compute by reducing the base first.
Recall Solution 2.3
Why look at the base: if the base collapses to something tiny, the power rule makes the whole thing trivial. By the power rule . An even power of is : Answer: . ✓
Level 3 — Analysis
Exercise 3.1
Find the last digit of .
Recall Solution 3.1
Reframe: "last digit" value . So we want . Find the cycle of powers of : Once we hit , the pattern repeats every steps: What it looks like: a -step merry-go-round of last digits (see figure below). Land the exponent on the wheel: , so is a multiple of , i.e. it lands on the same slot as , which is . Answer: last digit of is . ✓

Exercise 3.2
Solve for in standard form.
Recall Solution 3.2
Why we're allowed to divide here: we may divide by only if . It is (GCD and LCM), so a modular inverse of exists. Find the inverse of mod : the number with . Test : . ✓ So . Multiply both sides by : Answer: . Check: . ✓
Exercise 3.3
Show that for every , and use it to explain the "digit-sum" divisibility rule for .
Recall Solution 3.3
Base fact: , so . Power rule: for every . Consequence: write any number by its digits : So and its digit sum are congruent mod . Therefore is divisible by exactly when its digit sum is. Example: , digit sum , and is a multiple of , so is too (). ✓
Level 4 — Synthesis
Exercise 4.1
Compute .
Recall Solution 4.1
Strategy: find the shortest power of that hits mod , then jump in strides of that length. So the powers cycle with period : Land the exponent: , remainder . So sits in the same slot as : Answer: . ✓ (This is exactly the mechanism behind Fermats Little Theorem: since is prime, ; here a shorter period appears, which divides .)
Exercise 4.2
Find a number with and , in the range .
Recall Solution 4.2
Why range : the two clocks (period and period ) only re-sync after steps, so there is exactly one answer mod — this is the Chinese Remainder Theorem. Search the class of the second condition: numbers that are : . Test each against :
- ✗
- ✓
Answer: . Check: (good) and (good). ✓
Exercise 4.3
Compute using two reductions (base, then a power cycle).
Recall Solution 4.3
Reduce the base: , so . Find the cycle of : then repeats — period . Land the exponent: , remainder , so sits where sits, namely . Answer: . ✓
Level 5 — Mastery
Exercise 5.1
Compute , then use it to find 's relationship to .
Recall Solution 5.1
Smart base rewrite: (since ). Negative representatives are legal and often smaller in size. Cycle of : That's period (matching Fermats Little Theorem for prime : ). Land the exponent: , a multiple of , so . Answer: , and it equals because . ✓
Exercise 5.2
An RSA-style toy: with modulus , encryption exponent , the ciphertext of a message is . If the message is , find . Then verify decryption with recovers (i.e. check ).
Recall Solution 5.2
Encrypt: . So . Decrypt: compute . Reduce smartly: , so . Result: . ✓ Decryption recovers the message — the round-trip works because and for these keys. Answer: , and .
Exercise 5.3
Prove: if , then . Then use it to explain why has no inverse mod but does.
Recall Solution 5.3
Proof. means for an integer . Any common divisor of and divides , so divides and too. The argument runs symmetrically (write ). Hence the set of common divisors of equals that of , so their greatest members match: Application. An inverse of mod exists iff (Modular Inverses).
- → no inverse: shares the factor with , so can never land on .
- → inverse exists. Find it: , so . ✓
Recall Self-test: state the answers out loud
? ::: Yes (). in standard form ::: ::: Last digit of ::: Solve ::: ::: in ::: ::: ::: Toy RSA for ::: Does have an inverse mod ? ::: No, .