Comparisons, selection and current state
This is a fixed question bank. Later sets may repeat these questions
Initially x = 3
Each numbered row is one separate IF/ELSE decision: test its condition once using the current x, then run only the matching true or false column
The arrow ← assigns a value; = in a test checks equality without changing x. The comparisons ≤ and ≥ include equality, while < and > exclude it; ≠ means not equal
| Step | Test current value | If true | If false |
|---|---|---|---|
| 1 | x = 5 | x ← x + 2 | x ← x + 1 |