Find (733·339 + 334) mod 8 without multiplying out the large numbers: reduce first.
Number theory & modular arithmetic worksheet with answers
1.Easy
n = 8
(733·339 + 334) mod 8 =
2.Easy
Find the least common multiple lcm(40, 24). Use Euclid’s algorithm for the gcd first.
a = 40b = 24
lcm(40, 24) =
3.Medium
Find Euler’s totient φ(147), the number of integers from 1 to 147 that are coprime to 147.
n = 147 = 3·72
φ(147) =
4.Medium
Find the smallest positive integer x with x ≡ 4 (mod 7) and x ≡ 3 (mod 8).
x ≡ 4 (mod 7)x ≡ 3 (mod 8)
x =
5.Hard
73 is prime. Use Fermat’s little theorem to find 1154065 mod 73.
p = 73k = 54065
1154065 mod 73 =
6.Hard
Encrypt the message m = 440 with the RSA public key (n, e) = (493, 3). Find the ciphertext c.
n = 493e = 3m = 440
c =
Answer key
- 1. (733·339 + 334) mod 8 = 5
- 2. lcm(40, 24) = 120
- 3. φ(147) = 84
- 4. x = 11
- 5. 1154065 mod 73 = 42
- 6. c = 9
Full step-by-step solutions: practise this topic on examproblems.com.