What happens when variable shadowing occurs in JavaScript?
A local variable hides a global variable with the same name
A function is unable to access global variables
Variables are reset to default values
JavaScript automatically changes the value of the variable.
This question is part of this quiz :
JavaScript Basics Quiz