What is Hoisting
console.log(message); //output : undefined
var message = 'The variable Has been hoisted';
The above code looks like as below to the interpreter,
message = 'The variable Has been hoisted';
If you like this question & answer and want to contribute, then write your question & answer and email to freewebmentor[@]gmail.com. Your question and answer will appear on FreeWebMentor.com and help other developers.