构造函数定义
function Car(sColor, iDoors, iMpg) {
this.color = sColor;
this.doors = iDoors;
this.mpg = iMpg;
this.drivers = new Array("mike", "sue");
if (typeof Car.initialized == "undefined") {
Car.prototype.showColor = function() {
alert(this.color);
};
Car.initialized = true;
}
}
var car1 = new Car("red", 4, 23);
var car2 = new Car("blue", 3, 25);
car1.drivers.push("matt");
alert(car1.drivers); // outputs "mike,sue,matt"
alert(car2.);
.(car1 );

