Edexcel D1 2002 June — Question 5 11 marks

Exam BoardEdexcel
ModuleD1 (Decision Mathematics 1)
Year2002
SessionJune
Marks11
PaperDownload PDF ↗
Mark schemeDownload PDF ↗
TopicSorting Algorithms
TypeAlgorithm Tracing
DifficultyEasy -1.2 This is a straightforward algorithm tracing exercise requiring students to follow a flowchart step-by-step with given values (Euclidean algorithm for GCD). It involves only arithmetic operations and table completion with no problem-solving or proof, making it significantly easier than average A-level questions.
Spec7.03c Working with algorithms: trace, interpret, adapt

5. An algorithm is described by the flow chart below. \includegraphics[max width=\textwidth, alt={}, center]{652477eb-87dc-4a5a-8514-c9be39986142-5_1590_1264_363_539}
  1. Given that \(a = 645\) and \(b = 255\), complete the table in the answer booklet to show the results obtained at each step when the algorithm is applied.
  2. Explain how your solution to part (a) would be different if you had been given that \(a = 255\) and \(b = 645\).
  3. State what the algorithm achieves.

Question 5:
Part (a)
AnswerMarks Guidance
AnswerMarks Guidance
\(a=645,\ b=255,\ c=2.53,\ d=2,\ e=510,\ f=135\), \(f=0\)? NoM1 A1
\(a=255,\ b=135,\ c=1.89,\ d=1,\ e=135,\ f=120\), \(f=0\)? NoM1 A1
\(a=135,\ b=120,\ c=1.13,\ d=1,\ e=120,\ f=15\), \(f=0\)? NoA1
\(a=120,\ b=15,\ c=8,\ d=8,\ e=120,\ f=0\), \(f=0\)? YesA1
The answer is 15A1 (7)
Part (b)
AnswerMarks Guidance
AnswerMarks Guidance
The first row would be: \(255\ \ 645\ \ 0.40\ \ 0\ \ 0\ \ 255\ \ \text{No}\)M1 A1
But the second row would then be the same as the first row above, and the solution thereafter would be the same.A1 (3)
Part (c)
AnswerMarks Guidance
AnswerMarks Guidance
Finds the H.C.F of \(a\) and \(b\)B1 (1)
(11 marks)
# Question 5:

## Part (a)
| Answer | Marks | Guidance |
|--------|-------|----------|
| $a=645,\ b=255,\ c=2.53,\ d=2,\ e=510,\ f=135$, $f=0$? No | M1 A1 | |
| $a=255,\ b=135,\ c=1.89,\ d=1,\ e=135,\ f=120$, $f=0$? No | M1 A1 | |
| $a=135,\ b=120,\ c=1.13,\ d=1,\ e=120,\ f=15$, $f=0$? No | A1 | |
| $a=120,\ b=15,\ c=8,\ d=8,\ e=120,\ f=0$, $f=0$? Yes | A1 | |
| The answer is 15 | A1 | **(7)** |

## Part (b)
| Answer | Marks | Guidance |
|--------|-------|----------|
| The first row would be: $255\ \ 645\ \ 0.40\ \ 0\ \ 0\ \ 255\ \ \text{No}$ | M1 A1 | |
| But the second row would then be the same as the first row above, and the solution thereafter would be the same. | A1 | **(3)** |

## Part (c)
| Answer | Marks | Guidance |
|--------|-------|----------|
| Finds the H.C.F of $a$ and $b$ | B1 | **(1)** |
| | **(11 marks)** | |

---
5. An algorithm is described by the flow chart below.\\
\includegraphics[max width=\textwidth, alt={}, center]{652477eb-87dc-4a5a-8514-c9be39986142-5_1590_1264_363_539}
\begin{enumerate}[label=(\alph*)]
\item Given that $a = 645$ and $b = 255$, complete the table in the answer booklet to show the results obtained at each step when the algorithm is applied.
\item Explain how your solution to part (a) would be different if you had been given that $a = 255$ and $b = 645$.
\item State what the algorithm achieves.
\end{enumerate}

\hfill \mbox{\textit{Edexcel D1 2002 Q5 [11]}}