Answers
Answers
2. ReferenceError: let is not hoisted in the same way as var and will throw a ReferenceError.
4. undefined: Similar to the first question, var is hoisted and initialized to undefined.
5. ReferenceError: let has block scope and is not accessible outside its block.
10. ReferenceError: let variables are not hoisted and will cause an error.
15. ReferenceError: let variables are not hoisted and will cause an error.
16. 190: The let inside the block does not affect the var declared outside the block.
20. 260: The inner function has access to the x declared in outer due to lexical scoping.