JavaScript | Advanced JavaScript | Question 2

Last Updated :
Discuss
Comments

What will the following code log?

JavaScript
console.log(a);
var a = 10;


10

undefined

Error

null

Share your thoughts in the comments