1.对象定义 定义属性 var language = { name:'javascript', score:9.0 }; console.log(language.name) console.log(language.score) 定义方法 var language = { name:'javascript', score:9.0, percent: function () { var result = this.score/10*100 + '%'; return result; } }; c…