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.
Print with a capital P?Draw a line connecting each item on the left to its match on the right.
| Left column | Right column | |
|---|---|---|
| 1print area | AAlgorithm: find area input l, w area <- l * w print area | |
| 2print total / count | BWrong — print must come after input and processing. Printing result before n has been entered and result has been calculated produces no meaningful output | |
| 3print outputs the result after all input and processing has been completed | CEvaluates the expression total divided by count and outputs the computed result directly without storing it in a variable | |
| 4Capital-P Print is used in Software Development Begin...End pseudocode, not in VCAA maths pseudocode | DOutputs the current value stored in the variable area to display it as the result of the algorithm | |
| 5display answer | EBegin result <- a + b Print result End | |
| 6print result input n result <- n * 2 | FWrong — `display` is not a VCAA pseudocode keyword. The correct output keyword is `print`. The line should read `print answer` |
Complete each line of code by filling in the missing parts.
Shade in the letter of the line that contains an error.
print — A VCAA pseudocode keyword that outputs a value, variable or expression as a result. Example: print area displays the current value stored in the variable areaprint areaAlgorithm: show total
input a, b
total <- a + b
print totalinput x
result <- x * 2
print resultaverage <- total / count
print averageBegin
result <- a + b
Print result
End