1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
| public class Test1 {
public static void main(String[] args) {
Voiture car_1 = new Voiture("Renault", "Mégane", 13900.85, 2004);
car_1.Affiche();
Voiture car_2 = new Voiture("Peugeot", "407", 16900.85, 2005);
car_2.Affiche();
Voiture car_3 = new Voiture("Citroën", "C6", 28900.85, 2006);
car_3.Affiche();
Garage1 concess_1 = new Garage1("Dabireau", car_1, car_2, car_3);
concess_1.Affiche();
Voiture [] tabTempVoiture= {car_1, car_2, car_3};
Garage1 g1=new Garage1("Dabireau_bis", tabTempVoiture);
g1.Affiche();
Garage2 concess_2 = new Garage2("Saroteau", car_1, car_2, car_3);
concess_2.Affiche();
}
} |
Partager