A flowchart depicts a process, its decisions and its flow of control, and it can represent the logic of a program so you can trace it. This unit covers the standard flowchart symbols and how to trace a flowchart to follow execution, track variable changes and work out the output. (This is B1.1.4, common to SL and HL, with no AHL-only material.)
1. In a standard flowchart, which symbol is used for a decision with two possible outcomes, such as a yes/no question?
2. What does a parallelogram represent in a standard flowchart?
3. A flowchart sets A = 2 and B = 20. It then repeats these steps: check "is A greater than B?"; if the answer is no, do B = B - 4 then A = A + 2 and check again; if the answer is yes, stop. How many times does the pair of updates (B = B - 4, A = A + 2) run before the program stops?
4. A flowchart sets X = 5 and COUNT = 0. It then repeats: check "is X equal to 0?"; if no, do X = X - 1 then COUNT = COUNT + 2 and check again; if yes, output COUNT. What value is output?
Free revision content. Multiple-choice answers are marked instantly. Written answers are marked by AI on /free-mark.