An algorithm is a finite list of exact steps; a flowchart draws it with standard symbols. Tracing follows the values step by step to find the output or a bug.
| Oval | start or stop |
| Parallelogram | input or output |
| Rectangle | a process, such as a calculation |
| Diamond | a decision with a yes or no answer |
| Arrow; small circle | direction of flow; connector |
| Swap with a spare | T = A, A = B, B = T |
| Reverse digits | R = R × 10 + last digit of N, then remove that digit (1234 → 4321) |
Put the steps of an algorithm for charging a tablet in order. Write the letters in order.
(a) Find the charger
(b) Check that the charging sign appears
(c) Plug the charger into the socket
(d) Connect the cable to the tablet
(e) Switch on the socket
Working: Find the charger → Plug the charger into the socket → Connect the cable to the tablet → Switch on the socket → Check that the charging sign appears
Answer: a, c, d, e, b