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 | |
|---|---|---|
| 1score = 42 | Aphone = "0412 345 678" | |
| 2hasFinished = True | BA phone number is stored as a number, so the leading 0 is lost. It should be text: phone = "0412345678". | |
| 3A phone number is text because you never add it and you need to keep the leading 0. | CA yes/no answer such as 'has finished' is a true/false value. | |
| 4Choose a number when you will calculate with the value, such as adding points. | DA yes/no answer is stored as text. It should be true/false: hasFinished = True. | |
| 5phone = 0412345678 | EA score is a whole number because you add it up and compare it to other scores. | |
| 6hasFinished = "yes" | Ftotal = score + 10 |
Complete each line of code by filling in the missing parts.
Shade in the letter of the line that contains an error.
choose a data type — Ask what you will do with the value: calculate with it (number), join or show it (text), or answer yes/no (true/false). A phone number is text because you never add it.score ← 42 // data type: numberphone ← "0412 345 678" // data type: texthasFinished ← true // data type: true/falsephone is text because we never add itscore is a number because we add scores