Number theory & modular arithmetic worksheet with answers

Free printable Number theory & modular arithmetic worksheet: 6 problems from easy to exam level, with an answer key. Print it or save it as a PDF.

For teachers: free to print, copy and use in class. Every new worksheet has new values and its own answer key. A link to ExamProblems on your course page is appreciated.

Name: ____________________   Date: ____________

1.Easy
aqbr240=?·196+??=?·?+??=?·?+??=?·?+?

Use Euclid’s algorithm to find gcd(240, 196).

a = 240b = 196
gcd(240, 196) =
2.Easy

Find (570·711 + 88) mod 5 without multiplying out the large numbers: reduce first.

n = 5
(570·711 + 88) mod 5 =
3.Medium

Find the smallest positive integer x with x ≡ 4 (mod 8) and x ≡ 8 (mod 13).

x ≡ 4 (mod 8)x ≡ 8 (mod 13)
x =
4.Medium

Find the inverse of 20 modulo 67: the number x with 0 < x < 67 and 20·x ≡ 1 (mod 67).

a = 20n = 67
20−1 mod 67 =
5.Hard

53 is prime. Use Fermat’s little theorem to find 363098 mod 53.

p = 53k = 63098
363098 mod 53 =
6.Hard

73 is prime. Use Fermat’s little theorem to find 1955293 mod 73.

p = 73k = 55293
1955293 mod 73 =

Answer key

  1. 1. gcd(240, 196) = 4
  2. 2. (570·711 + 88) mod 5 = 3
  3. 3. x = 60
  4. 4. 20−1 mod 67 = 57
  5. 5. 363098 mod 53 = 17
  6. 6. 1955293 mod 73 = 24

Full step-by-step solutions: practise this topic on examproblems.com.