Skip to content

Instantly share code, notes, and snippets.

Created June 15, 2017 21:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save anonymous/8ae7e7234e52883d3e6f8d02a5ac1cf1 to your computer and use it in GitHub Desktop.
Save anonymous/8ae7e7234e52883d3e6f8d02a5ac1cf1 to your computer and use it in GitHub Desktop.
null created by dtstanley - https://repl.it/Indd/1
var person ={
name: ['Bob', 'Smith'],
age:32,
gender:'male',
interests: ['music','skiing'],
bio: function(){
alert(this.name[0] + ' ' +this.name[1] + ' is ' + this.age + ' years old. He likes ' + this.interests[0] + ' and ' + this.interests[1] + '.');
},
greeting: function(){
alert('Hi! I\'m ' + this.name[0] + '.');
}
};
person.name[0] = ['Stephens'];
person.age= [44];
person.interests[1]=['the bible'];
person.bio();
person.greeting();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment