Tip: Choose Save as PDF in the print dialog to download. Use A4 paper size.
Shade in the A or B circle for each question.
Draw a line connecting each item on the left to its match on the right.
| Left column | Right column | |
|---|---|---|
| 1end if | AThe closing keyword for an if block in VCAA pseudocode; end is always followed by a space and the keyword that opened the block | |
| 2if temp > 30 then print "hot" else print "cold" end if | Bx <- 5 y <- x + 1 print y | |
| 3One statement per line is a core VCAA pseudocode writing convention | Cfor i from 1 to 5 print i end for | |
| 4Indentation shows which lines belong inside a nested block such as a loop or if statement | DWrong — VCAA pseudocode requires one statement per line. Semicolons are not used. `x <- 5` and `print x` must each be on their own line | |
| 5if age > 18 then print "ok" endif | EA snippet showing all three VCAA conventions: one statement per line, the body indented inside each block, and end if closing the construct | |
| 6x <- 5; print x if x > 0 then print "ok" end if | FWrong — VCAA pseudocode writes this as two words: `end if`. The closing keyword always separates end from the block name with a space |
Complete each line of code by filling in the missing parts.
Shade in the letter of the line that contains an error.
end if — A closing keyword in VCAA pseudocode that ends an if block; every nested construct uses end followed by its matching keyword: end if, end while, end forif score > 50 then
print score
end ifwhile count < 10
print count
end whilefor i from 1 to 5
print i
end forif x > 5 then
print x
end ifif a > b then
print a
end if