Advertisement
achshar

Untitled

May 14th, 2013
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. var setName = function(yourName){
  2.     this.name = "Your name is " + yourName;
  3. };
  4.  
  5. var human = {
  6.     setHumanName: setName
  7. };
  8.  
  9. human.setHumanName("hey");
  10. console.log(human.name);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement