If functional declarations are hoisted before the variable declaration .In that case ,Why I am getting the functional definition instead of undefined.
function a(){}
var a;
console.log(a); // ƒ a(){}
I am expecting that the variable declaration will override the functional declaration and become undefined
Since you're not assigning a value to a variable and in hoisting JS place an undefined value to a variable. undefined does not override any value, that's why you're getting a function.