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 | |
|---|---|---|
| 1Day = "Sat" OR Day = "Sun" | ATRUE if the day is Saturday or Sunday (the weekend) | |
| 2Mark < 0 OR Mark > 100 | BAND is used where OR is needed. No score can be below 0 and above 100 at once, so the condition is never TRUE. It should be OR. | |
| 3OR is only FALSE when both conditions are FALSE | Cx <- 10 IF x > 5 OR x > 8 THEN | |
| 4OR is still TRUE when both conditions are TRUE | DTRUE if the mark is outside the valid range 0 to 100 | |
| 5IF Day = "Sat" OR "Sun" THEN | EIF Age < 5 OR Age > 65 THEN | |
| 6IF Score < 0 AND Score > 100 THEN | FEach side of OR must be a full condition. "Sun" on its own is not a condition. It should be Day = "Sat" OR Day = "Sun". |
Complete each line of code by filling in the missing parts.
Shade in the letter of the line that contains an error.
OR — Joins two conditions. The result is TRUE when at least one condition is TRUE, e.g. Day = "Sat" OR Day = "Sun". It is only FALSE when both conditions are FALSE.IF Day = "Sat" OR Day = "Sun" THEN
OUTPUT "Weekend"
ENDIFIF Mark < 0 OR Mark > 100 THEN
OUTPUT "Invalid mark"
ENDIFIF Age < 5 OR Age > 65 THEN
OUTPUT "Free ticket"
ENDIFWet <- TRUE
Cold <- TRUE
OUTPUT Wet OR ColdIF Letter = "a" OR Letter = "e" THEN
OUTPUT "Vowel"
ENDIF