
C D Quiz 3
Quiz by crio
Feel free to use or edit a copy
includes Teacher and Student dashboards
Measure skillsfrom any curriculum
Tag the questions with any skills you have. Your dashboard will track each student's mastery of each skill.
- edit the questions
- save a copy for later
- start a class game
- automatically assign follow-up activities based on students’ scores
- assign as homework
- share a link with colleagues
- print as a bubble sheet
- Q1
Which keyword is used to declare a variable with block scope in JavaScript?
const
let
var
function
30s - Q2
What is the output of the following JavaScript code snippet? var x = 10; { let x = 20; console.log(x); } console.log(x);
20, 10
20, 20
10, 20
10, 10
30s - Q3
What is the difference between 'let' and 'const' when declaring variables in JavaScript?
'let' allows for hoisting while 'const' does not
'let' allows variable reassignment while 'const' does not
'let' is used for global variables while 'const' is used for local variables
'let' has block scope and 'const' has function scope
30s - Q4
Which keyword allows for variable hoisting in JavaScript?
let
const
dynamic
var
30s - Q5
What is the purpose of using 'const' keyword to declare variables in JavaScript?
'const' variables have global scope and can be accessed from any part of the code.
'const' variables are only accessible within the block they are defined in.
'const' variables can be reassigned multiple times with different values.
'const' variables are used to create constants, whose value cannot be changed once assigned.
30s