예제 #1
0
 public Car(string model, int speed, int power, int weight, string type)
 {
     Model     = model;
     NewEngine = new Engine(speed, power);
     NewCargo  = new Cargo(weight, type);
 }
예제 #2
0
 public Car(string model, Engine engine, Cargo cargo)
 {
     this.Model  = model;
     this.Engine = engine;
     this.Cargo  = cargo;
 }