Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save jgermade/4ec6e55d1bd2124e922dd87d0486d5a4 to your computer and use it in GitHub Desktop.
Save jgermade/4ec6e55d1bd2124e922dd87d0486d5a4 to your computer and use it in GitHub Desktop.
function Father(first_name) {
this.first_name = name;
}
var John = new Father('John');
function Son() {
Father.apply(this, arguments);
}
Son.prototype = John;
var Johnny = new Son('Johnny');
Johnny.last_name
John.last_name = 'Smith';
Johnny.last_name
function sum (a, b, c) {
return a+b+c;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment