摘要:
1functionPerson(){2}34Person.prototype.name="Nicholas";5Person.prototype.age=29;6Person.prototype.job="SoftwareEngineer";7Person.prototype.sayName=function(){8console.log(this.name);9};1011varperson1=newPerson();12person1.sayName();1314varperson2=newPerson();15person2.sayName();1 阅读全文