Question: are let and const hoisted?
Answer: Yes, variables declared with let and const are hoisted. Where they differ from other declarations in the hoisting process is in their initialization. During the compilation phase, JavaScript variables declared with var and function are hoisted and automatically initialized to undefined .