Use Euclid’s algorithm to find gcd(53, 20).
Number theory & modular arithmetic worksheet with answers
1.Easy
a = 53b = 20
gcd(53, 20) =
2.Easy
Use Euclid’s algorithm to find gcd(288, 81).
a = 288b = 81
gcd(288, 81) =
3.Medium
Find the inverse of 54 modulo 83: the number x with 0 < x < 83 and 54·x ≡ 1 (mod 83).
a = 54n = 83
54−1 mod 83 =
4.Medium
Find Euler’s totient φ(361), the number of integers from 1 to 361 that are coprime to 361.
n = 361 = 192
φ(361) =
5.Hard
An RSA key uses p = 37, q = 47 and e = 13. Decrypt the ciphertext c = 207: find the message m.
p = 37q = 47e = 13c = 207
m =
6.Hard
How many solutions N does 54x ≡ 72 (mod 78) have in {0, 1, …, 77}?
54x ≡ 72 (mod 78)
N =
Answer key
- 1. gcd(53, 20) = 1
- 2. gcd(288, 81) = 9
- 3. 54−1 mod 83 = 20
- 4. φ(361) = 342
- 5. m = 1515
- 6. N = 6
Full step-by-step solutions: practise this topic on examproblems.com.