2026 P-I Q40 froze many students. The pseudocode said REPEAT ... UNTIL n < 1, and Python has no REPEAT. Students knew while, but not where to split the loop. That is not a gap in what they know. It is a gap in the picture, and the books never draw it. The Sinhala paper calls pseudocode "ව්යාජ කේතය".
The question is older than it looks. Since 2013 P-I Q19, the paper has asked "which Python code matches this algorithm". From 2015 P-I Q31 on, most of those flowcharts put the test at the bottom, after the body. That is a REPEAT UNTIL loop drawn as a picture. 2026 only wrote it in words. Pseudocode is one of the ways to show an algorithm, and students hand trace it before they write code (Syllabus 9.3, page 36) (විෂය නිර්දේශය 9.3, පිටුව 34). The Sinhala syllabus calls them "ව්යාජ කේත(pseudo code)" and "හස්තානුරේඛන (hand traces)".
Two rules do the work. First, REPEAT tests at the bottom, so its body runs at least once, while while tests at the top. Second, UNTIL says when to stop and while says when to go on, so flip the condition: UNTIL n < 1 becomes while n >= 1. When in doubt, trace the pseudocode first. It prints 5 3 1. Then cross out every option that prints something else.
Our worked answer is (5), because the 2026 scheme is not out yet. Each wrong option hides one planted mistake: a copied condition, a wrong break test, a swapped order and a counter. The Explained post covers the traps, the full history since 2013 and the book gaps. It also shows six ways this pattern can come next. Read it in REPEAT UNTIL pseudocode to Python loops in 2026 MCQ 40.
