Signup/Sign In
Ask Question
Not satisfied by the Answer? Still looking for a better solution?

Js level 2 lesson 5

var myVar=null

console.log(myVar);

It is showing error create a new variable with name myVar. even though i created one. Can anyone help me?
by

1 Answer

kshitijrana14
Try this one:

// write your code here
var myVar;
console.log(myVar);
var myVar = null;
console.log(myVar);

Login / Signup to Answer the Question.