Beginner
JavaScript
Q1 / 100
Which keyword declares a block-scoped variable in modern JavaScript?
Correct! Well done.
Incorrect.
The correct answer is B) let
B
Correct Answer
let
Explanation
let declares a block-scoped variable. const is also block-scoped but cannot be reassigned. var is function-scoped and hoisted.
Progress
1/100