JavaScript_Interview_Questions
JavaScript_Interview_Questions
Q: What is JavaScript?
A: var is function-scoped, let and const are block-scoped. const can't be reassigned.
A: Closures are functions that retain access to variables from their lexical scope.
Q: What is hoisting?
A: Hoisting moves variable and function declarations to the top of their scope.
A: It allows you to handle events at a higher level and catch events from child elements.
Q: What is a promise?
Q: What is async/await?
A: Concise syntax for writing functions, does not bind its own `this`.