Untitled

mail@pastecode.io avatar
unknown
plain_text
2 years ago
412 B
0
Indexable
Never
// Declare the myGlobal variable below this line
let oopsGlobal;
let myGlobal;

function fun1() {
  // Assign 5 to oopsGlobal Here
  oopsGlobal = 5;
  myGlobal = 10;
}

// Only change code above this line

function fun2() {
  var output = "";
  if (typeof !myGlobal) {
    output += "myGlobal: " + myGlobal;
  }
  if (typeof !oopsGlobal) {
    output += " oopsGlobal: " + oopsGlobal;
  }
  console.log(output);
}