The algorithms in Figure 1 and Figure 2 have the exact same computational purpose.
Figure 1
result ← number LEFTSHIFT 2
result ← result + number
Figure 2
result ← 0
FOR i ← 1 TO 5
result ← result + number
ENDFOR
State this purpose.
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.