D1 June 2005 Q1
1.
| Ali | 74 |
| Bobby | 28 |
| Eun-Jung | 63 |
| Katie | 54 |
| Marciana | 54 |
| Peter | 49 |
| Rory | 37 |
| Sophie | 68 |
The table shows the marks obtained by students in a test. The students are listed in alphabetical order. Carry out a quick sort to produce a list of students in descending order of marks. You should show the result of each pass and identify your pivots clearly. (5)
| Scheme | Marks |
|---|---|
e.g.![]() | M1 A1 A1ft A1 (4) |
| \(\therefore\) Ali, Sophie, Eun-Jung, {Katie + Marciana}, Peter, Rory, Bobby | A1 (1) |
| (5 marks) |
Notes
Pivots are circled (pivots by pass: 54; 54, 49; 63, 37; 68, (28)); numbers in their final positions are boxed. The rows read:
74 28 63 54 54 49 37 68
74 63 54 68 54 28 49 37
74 63 68 54 54 49 28 37
74 68 63 54 54 49 37 28
74 68 63 54 54 49 37 28
74 68 63 54 54 49 37 28 sort complete
