Created
November 20, 2013 00:20
-
-
Save roryf/7555133 to your computer and use it in GitHub Desktop.
Pop quiz
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var one = { | |
name: 'one', | |
hello: function() { | |
console.log(this.name); | |
} | |
}; | |
var two = { | |
name: 'two' | |
}; | |
two.hello = one.hello; | |
two.hello(); // what gets printed? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment