Complete the trace table for the algorithm shown in Figure 1 when the initial value of scale is 3.
Figure 1
product ← 5
FOR step ← 1 TO 3
product ← product * scale
ENDFOR
You may not need to use all rows of the trace table.
| scale | step | product |
|---|---|---|
| 3 | 5 | |
208 exam-style questions on AQA GCSE Computer Science Representing algorithms. Each one has a worked solution and a mark scheme showing where the marks go.