Check the following cases:-
function x() {
console.log('x');
};
x(); //outputs x
var y = function () {
console.log('y');
};
y(); //outputs y
var z = function w() {
console.log('zw')
};
z(); //outputs zw;
w(); //outputs .. w is not defined.
Can anyone explain me this behaviour..?