3秒回答javaScript this指向

3秒内,能回答出打印的值?

      window.name = 'globalName'; 
      var myObject = {     
        name: 'sven',     
        getName: function(){         
          return this.name;     
        } 
      }; 
      console.log( myObject.getName() );    // ?
      var getName = myObject.getName; 
      console.log( getName() );    // ?

你可能感兴趣的:(web前端技术,javascript,js)