Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class CarShop {
- public static void main(String[] args) {
- Car audi = new Car();
- audi.brand = "Audi";
- audi.model = "A4";
- audi.doors = 4;
- audi.carColor = "Czarny";
- audi.wheelsColor = "Srebrny";
- audi.tiresColor = "Czarny";
- String audiInfo = audi.brand + " " + audi.model
- + ", Drzwi: " + audi.doors
- + ", Kolor nadwozia: " + audi.carColor
- + ", Kolor felg: " + audi.wheelsColor
- + ", Kolor opon: " + audi.tiresColor;
- System.out.println("Wybrałeś następujący samochód: ");
- System.out.println(audiInfo);
- }
- }
- ____________________________________________________________________________________________
- public class CarShop {
- static Car audi;
- public static void main(String[] args) {
- audi = new Car();
- audi.brand = "Audi";
- audi.model = "A4";
- audi.doors = 4;
- audi.carColor = "Czarny";
- audi.wheelsColor = "Srebrny";
- audi.tiresColor = "Czarny";
- String audiInfo = audi.brand + " " + audi.model
- + ", Drzwi: " + audi.doors
- + ", Kolor nadwozia: " + audi.carColor
- + ", Kolor felg: " + audi.wheelsColor
- + ", Kolor opon: " + audi.tiresColor;
- System.out.println("Wybrałeś następujący samochód: ");
- System.out.println(audiInfo);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement