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 | |
|---|---|---|
| 17.0 | A"7" | |
| 2'7' | B"TRUE" in double quotes is a STRING, not a BOOLEAN. It should be written as TRUE with no quotes. | |
| 3Double quotes around the characters make a STRING literal, even when they look like a number | CA REAL literal, because it is written with a decimal point | |
| 4TRUE written with no quotes is a BOOLEAN literal | DTRUE | |
| 5Flag ← "TRUE" // Flag is BOOLEAN | EA CHAR literal, because it is in single quotes | |
| 6Grade ← "A" // Grade is CHAR | F"A" in double quotes is a STRING. A CHAR literal needs single quotes, so it should be 'A'. |
Complete each line of code by filling in the missing parts.
Shade in the letter of the line that contains an error.
7 7.0 '7' "7" TRUE — How a literal is written shows its type: digits = INTEGER, decimal point = REAL, single quotes = CHAR, double quotes = STRING, TRUE or FALSE = BOOLEAN.DECLARE Count : INTEGER
Count ← 7DECLARE Price : REAL
Price ← 7.0DECLARE Letter : CHAR
Letter ← '7'DECLARE Word : STRING
Word ← "TRUE"DECLARE Done : BOOLEAN
Done ← TRUE