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 | |
|---|---|---|
| 1function greet() { ... } | A() | |
| 2greet(); | BRuns the code inside the greet function | |
| 3The keyword used to declare a function | Cfunction | |
| 4Follows a function's name in its declaration | DDeclares a reusable function named greet | |
| 5Function greet() { console.log("Hi"); } | EWrong - missing the parentheses after the function name | |
| 6function wave { console.log("Wave"); } | FWrong - 'function' must be lowercase |
Complete each line of code by filling in the missing parts.
Shade in the letter of the line that contains an error.
function — Declares a reusable block of code with a name, which can be run later by calling it.function greet() {function greet() {function sayBye() {function sayBye() {greet();