Programming · 4 question types
Past paper frequency (2018 to 2024)
This topic accounts for approximately 13% of your exam marks.
Paper 2 is almost entirely programming. Variable types, assignments, loops and conditionals are tested every session.
A short reminder of every operator and function on one page.
DECLARE Identifier : DataType
CONSTANT Identifier ← Value
INTEGER | REAL | CHAR | STRING | BOOLEAN |
|---|
+ | - | * | / | DIV | MOD | ^ |
|---|
= | <> | < | > | <= | >= |
|---|
AND | OR | NOT |
|---|
LENGTH(s) | SUBSTRING(s, start, length) | UCASE(s) | LCASE(s) |
|---|
= for equality in CIE pseudocode (not ==).CHAR, double quotes for STRING.← (or = in some specs) for assignment; do not mix with the equality =.MOD for "is divisible by" rather than dividing and checking the fractional part.