This University number theory and discrete mathematics worksheet with answers has 20 questions for pupils aged 18-19, from short skills practice to real-life problems. The worked answers are on a separate page, so you can try every question first.
Question 1 β The Euclidean algorithm and Bezout (Section A Β· Skills practice)
Let \(a=1071\) and \(b=462\).
- Use the Euclidean algorithm to find \(\gcd(1071,462)\). [3 marks]
- Work backwards to write the gcd in the form \(1071x+462y\) with integers \(x,y\). [3 marks]
- Find \(\operatorname{lcm}(1071,462)\). [2 marks]
Question 2 β Inverses and linear congruences (Section A Β· Skills practice)
Work modulo the number given in each part.
- Find the inverse of 11 modulo 26. [3 marks]
- Solve \(11x\equiv5\pmod{26}\). [2 marks]
- Solve \(6x\equiv4\pmod{10}\), giving all solutions modulo 10. [3 marks]
Question 3 β Fermat and Euler (Section A Β· Skills practice)
Use Fermat's little theorem or Euler's theorem; do not use a calculator for the powers.
- Find \(5^{100}\bmod13\). [3 marks]
- Compute \(\varphi(360)\). [2 marks]
- Find the last digit of \(7^{222}\). [3 marks]
Question 4 β The Chinese remainder theorem (Section A Β· Skills practice)
Solve each system of congruences.
- \(x\equiv2\pmod3\), \(x\equiv3\pmod5\), \(x\equiv2\pmod7\). [4 marks]
- \(x\equiv1\pmod4\), \(x\equiv4\pmod9\). [3 marks]
Question 5 β Counting techniques (Section A Β· Skills practice)
Answer each counting question, showing the principle used.
- How many different arrangements are there of the letters of BANANA? [2 marks]
- In how many ways can a committee of 4 be chosen from 12 people? [2 marks]
- How many integers from 1 to 1000 are divisible by 3, 5 or 7? [4 marks]
Question 6 β Degrees, trees and Euler trails (Section A Β· Skills practice)
Answer each part about simple graphs.
- A graph has degree sequence \(4,4,3,3,2,2\). How many edges does it have? Does it have an Euler circuit or an Euler trail? [3 marks]
- A tree has 15 vertices. How many edges does it have? [1 mark]
- For which \(n\) does the complete graph \(K_n\) have an Euler circuit? How many edges does \(K_6\) have? [3 marks]
Question 7 β Tiling a kitchen floor (Section B Β· Real-life practice)
A kitchen floor is a rectangle 3.36 m by 2.52 m. A builder wants to cover it exactly with identical square tiles, as large as possible, without cutting any tile.
- Explain why the side of the tile (in cm) must be a common divisor of 336 and 252.
- Use the Euclidean algorithm to find the largest possible tile.
- How many tiles are needed?
- Tiles of that size cost Β£7.50 each. Find the total cost, and compare with 28 cm tiles at Β£1.20 each.
Question 8 β Postage with two stamps (Section B Β· Real-life practice)
A post office only has 5p and 8p stamps left. A parcel needs exactly 79p of postage.
- Explain why the equation \(5x+8y=79\) has integer solutions.
- Find one solution using \(5\times(-3)+8\times2=1\).
- Write the general solution and list all solutions with \(x,y\ge0\).
- Show that 27p cannot be made, and explain why every amount from 28p upwards can (the Frobenius number is \(5\times8-5-8\)).
Question 9 β Calendar arithmetic (Section B Β· Real-life practice)
1 January 2027 is a Friday. Days of the week repeat every 7 days, so we work modulo 7 (Friday \(=0\), Saturday \(=1\), β¦).
- 2027 is not a leap year. Use \(365\equiv1\pmod7\) to find the day of the week of 1 January 2028.
- What day of the week is 100 days after 1 January 2027?
- 2028 is a leap year. On what day of the week does 1 January 2029 fall?
- Explain why the same calendar can be reused only after several years.
Question 10 β ISBN check digits (Section B Β· Real-life practice)
An ISBN-10 \(d_1d_2\dots d_{10}\) is valid when \(10d_1+9d_2+8d_3+\dots+2d_9+1\cdot d_{10}\equiv0\pmod{11}\) (the symbol X stands for 10).
Position 1 2 3 4 5 6 7 8 9 10 Digit 0 3 0 6 4 0 6 1 5 ? Weight 10 9 8 7 6 5 4 3 2 1 - Find the weighted sum of the first nine digits.
- Find the check digit.
- A librarian types the 4 in position 5 as a 7. Show that the error is detected.
- Explain why any single wrong digit is always detected (use that 11 is prime).
Question 11 β A toy RSA code (Section B Β· Real-life practice)
Two friends use a small RSA code. The public key is \(n=55=5\times11\) and \(e=3\).
- Find \(\varphi(55)\).
- Find the private key \(d\) with \(3d\equiv1\pmod{\varphi(n)}\).
- Encrypt the message \(m=8\) by computing \(c=m^3\bmod55\).
- Decryption computes \(c^d\bmod55\). Explain why this returns 8 and why real RSA uses primes with hundreds of digits.
Question 12 β How strong is a password? (Section B Β· Real-life practice)
A website requires passwords of exactly 8 characters, each a lower-case letter (26 choices) or a digit (10 choices).
- How many passwords are possible?
- How many contain at least one digit?
- An attacker can test \(10^9\) passwords per second. How long does it take to try them all?
- How many times more passwords are there if upper-case letters are also allowed?
Question 13 β Planning a five-a-side league (Section B Β· Real-life practice)
Eight five-a-side football teams play a league where every team plays every other team exactly once. Model the teams as vertices and the matches as edges.
- Which graph is this? How many matches are played?
- What is the degree of each vertex, and what does it mean?
- Each team plays at most one match per evening. Explain why at least 7 evenings are needed.
- The league adds a ninth team. How many matches now, and why can no evening have all teams playing?
Question 14 β The gritter's route (Section B Β· Real-life practice)
A gritting lorry must treat every street of a village exactly once. The junctions \(A\) to \(F\) and the number of streets meeting at each are shown.
Junction A B C D E F Degree 2 3 4 2 3 2 - How many streets are there?
- Can the lorry start and finish at the depot at \(A\) without repeating a street? Explain.
- Where must the lorry start and finish to treat each street exactly once?
- The council adds one street to make an Euler circuit possible. Between which junctions should it go?
Question 15 β Domino tilings and Fibonacci (Section C Β· Problem solving)
A garden path is a \(2\times n\) strip made of square slabs. It is covered by \(1\times2\) paving stones (dominoes), each placed either across or along the path. Let \(t_n\) be the number of tilings.
\(n\) 1 2 3 4 5 \(t_n\) 1 2 3 5 8 - Explain why \(t_n=t_{n-1}+t_{n-2}\) for \(n\ge3\) by looking at the left end of the strip.
- Compute \(t_{10}\).
- Show that the characteristic equation \(r^2=r+1\) has roots \(\phi=\dfrac{1+\sqrt5}2\) and \(\psi=\dfrac{1-\sqrt5}2\).
- Prove by strong induction that \(t_n\le2^{n-1}\) for all \(n\ge1\).
- Estimate \(\dfrac{t_{20}}{t_{19}}\) and explain.
Question 16 β A population recurrence (Section C Β· Problem solving)
Ecologists model a population of beetles (in hundreds) by \(a_n=a_{n-1}+6a_{n-2}\) with \(a_0=1\) and \(a_1=8\), where \(n\) counts seasons.
\(n\) 0 1 2 3 4 \(a_n\) 1 8 ? ? ? - Complete the table.
- Find the roots of the characteristic equation.
- Find the closed form \(a_n=A\cdot3^n+B(-2)^n\).
- Check your formula for \(n=4\) and find \(a_{10}\).
- Describe the long-term growth.
Question 17 β How many in the marching band? (Section C Β· Problem solving)
A marching band has between 100 and 300 members. When they march in rows of 4, three are left over; in rows of 5, two are left over; in rows of 7, one is left over.
- Write the information as three congruences.
- Explain why the Chinese remainder theorem gives exactly one solution modulo 140.
- Solve the system step by step.
- Find all possible sizes of the band.
- The band leader says there are more than 200. How many members are there?
Question 18 β Scheduling exams with graph colouring (Section C Β· Problem solving)
A sixth-form college must timetable six exams: Maths (M), Physics (P), Chemistry (C), Biology (B), Economics (E) and History (H). Two exams that share a student cannot be in the same session. The clashes are listed below.
Exam Clashes with M P, C, H P M, C, E C M, P, B B C, E E B, H, P H E, M - Draw the clash graph and count its edges using the handshaking lemma.
- Explain why at least 3 sessions are needed.
- Give a timetable with 3 sessions.
- What is the chromatic number of the graph?
- A new student takes both Biology and History. Can 3 sessions still be used?
Question 19 β Proofs by induction (Section C Β· Problem solving)
Mathematical induction is the main tool for proving statements about all natural numbers. Prove each statement for all integers \(n\ge1\) and test it numerically first.
\(n\) 1 2 3 4 \(7^n-1\) 6 48 342 2400 \(3^{2n}-1\) 8 80 728 6560 - Check that every entry in the table has the divisibility claimed below.
- Prove that \(6\) divides \(7^n-1\).
- Prove that \(8\) divides \(3^{2n}-1\).
- Prove that \(1\cdot1!+2\cdot2!+\dots+n\cdot n!=(n+1)!-1\).
Question 20 β Challenge: factorials and primes (Section D Β· Challenge)
Factorials contain many prime factors. Legendre's formula says that the power of a prime \(p\) in \(n!\) is \(\left\lfloor\frac np\right\rfloor+\left\lfloor\frac n{p^2}\right\rfloor+\left\lfloor\frac n{p^3}\right\rfloor+\cdots\).
- Find the highest power of 2 dividing \(50!\).
- How many zeros does \(100!\) end with? And \(1000!\)?
- Check Wilson's theorem \((p-1)!\equiv-1\pmod p\) for \(p=7\) and \(p=11\).
- Show that \((n-1)!\equiv0\pmod n\) when \(n=ab\) with \(1\lt a\lt b\lt n\), so Wilson's congruence characterises primes (apart from \(n=4\)).
How to use this University number theory and discrete mathematics worksheet with answers
First, read the number theory and discrete mathematics lesson so that the methods are fresh in your mind. Then answer the questions in order, because they start easy and get harder. Show your working on paper; afterwards, compare it with the worksheet answers. If a question goes wrong, look back at the matching example before you try again. Finally, when you feel confident, try the number theory and discrete mathematics test or the quiz.
You can also download this University number theory and discrete mathematics worksheet with answers as a PDF and print it for homework. Moreover, all the pages of this chapter work together, so you can move between them at any time. For example, many pupils read the lesson on Monday, practise on Wednesday and test themselves on Friday. In short, this University number theory and discrete mathematics worksheet with answers prepares you well for the test.


















