static void Main(string[] args) { Marka marka = new Marka(); Tofas tofas = new Tofas(); Wolswogen wolswogen = new Wolswogen(); Audi audi = new Audi(); Console.WriteLine("---------Araba Markalari---------"); marka.MarkaGoster(); Console.Write("sectiginiz markanin ID numarasini giriniz : "); int secim = int.Parse(Console.ReadLine()); switch (secim) { case 1: tofas.TofasGoster(); break; case 2: audi.AudiGoster(); break; case 3: wolswogen.WolswogenGoster(); break; } }
public ArrayList WolswogenEkle(Wolswogen wolswogen) { //Wolswogen wolswogen = new Wolswogen(); //wolswogen.WolswogenID = 3; ArrayList wolswogenler1 = new ArrayList(); wolswogenler1.Add(wolswogen.Passat); wolswogenler1.Add(araba.KapiSayisi = 5); wolswogenler1.Add(araba.Motorgucu = 100); wolswogenler1.Add(araba.VitesTuru = "manuel"); wolswogenler1.Add(araba.YakitTuru = "dizel"); wolswogenler1.Add(araba.YapimYili = 2005); wolswogenler1.Add(araba.KaportaCinsi = "sedan"); wolswogenler.Add(wolswogenler1); ArrayList wolswogenler2 = new ArrayList(); wolswogenler2.Add(wolswogen.Golf); wolswogenler2.Add(araba.KapiSayisi = 3); wolswogenler2.Add(araba.Motorgucu = 120); wolswogenler2.Add(araba.VitesTuru = "otomatik"); wolswogenler2.Add(araba.YakitTuru = "benzin"); wolswogenler2.Add(araba.YapimYili = 2015); wolswogenler2.Add(araba.KaportaCinsi = "hecbeck"); wolswogenler.Add(wolswogenler2); ArrayList wolswogenler3 = new ArrayList(); wolswogenler3.Add(wolswogen.Polo); wolswogenler3.Add(araba.KapiSayisi = 5); wolswogenler3.Add(araba.Motorgucu = 100); wolswogenler3.Add(araba.VitesTuru = "otomatik"); wolswogenler3.Add(araba.YakitTuru = "dizel"); wolswogenler3.Add(araba.YapimYili = 2017); wolswogenler3.Add(araba.KaportaCinsi = "hecbeck"); wolswogenler.Add(wolswogenler3); return(wolswogenler); }