jsam
1/31/2015 - 2:12 PM

what is the output?

what is the output?

function test() {
   console.log(a);
   console.log(foo());
    
   var a = 1;
   function foo() {
      return 2;
   }
}
 
test();