摘要:
shape.prototype = { getEdge:function(){ return this.edge; }, getArea:function(){ return this.a*this.b; }}function shape(edge, a, b){ this.edge = edge; this.a = a; this.b = b;}//三角形继续形状triangle.prototype = new shape();triangle.prototype.getName = function(){alert('I... 阅读全文