Beispiel #1
0
        static void Main()
        {
            Laptop laptop = new Laptop("HP 250 G2", 699.00);
            Console.WriteLine(laptop);

            Battery batt = new Battery("Li-Ion, 4-cells, 2550 mAh", 4.5);
            Laptop laptop2 = new Laptop("Lenovo Yoga 2 Pro", "Lenovo", "Intel Core i5-4210U (2-core, 1.70 - 2.70 GHz, 3MB cache)", 8, "Intel HD Graphics 4400", "128GB SSD",
                "13.3\"(33.78 cm) – 3200 x 1800(QHD +), IPS sensor display", batt, 2259.00);
            Console.WriteLine(laptop2);
        }
Beispiel #2
0
 public Laptop(string currentModel, string currentManufacturer, string currentProcessor, int currentRam,
     string currentGraphicsCard, string currentHdd, string currentScreen, Battery 
     battery, double currentPrice)
     : this(currentModel, currentPrice)
 {
     this.Manufacturer = currentManufacturer;
     this.Processor = currentProcessor;
     this.Ram = currentRam;
     this.GraphicsCard = currentGraphicsCard;
     this.Hdd = currentHdd;
     this.Screen = currentScreen;
     this.batt = battery;
 }