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
aqbr494=?·299+??=?·?+??=?·?+??=?·?+??=?·?+?

Use Euclid’s algorithm to find gcd(494, 299).

a = 494b = 299
gcd(494, 299) =
2.Easy
aqbr92=?·58+??=?·?+??=?·?+??=?·?+??=?·?+??=?·?+?

Use Euclid’s algorithm to find gcd(92, 58).

a = 92b = 58
gcd(92, 58) =
3.Medium

Find Euler’s totient φ(1805), the number of integers from 1 to 1805 that are coprime to 1805.

n = 1805 = 5·192
φ(1805) =
4.Medium

Solve 6x ≡ 9 (mod 11). Give the solution x with 0 < x < 11.

6x ≡ 9 (mod 11)
x =
5.Hard

43 is prime. Use Fermat’s little theorem to find 246901 mod 43.

p = 43k = 46901
246901 mod 43 =
6.Hard

Solve 21x ≡ 18 (mod 33). Give the smallest positive solution x.

21x ≡ 18 (mod 33)
x =

Answer key

  1. 1. gcd(494, 299) = 13
  2. 2. gcd(92, 58) = 2
  3. 3. φ(1805) = 1368
  4. 4. x = 7
  5. 5. 246901 mod 43 = 2
  6. 6. x = 4

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