/*
  Lab exam 20/9/20025
  Test program Part 1
*/

public class TestCar {
	
  public static void main(String[] args) {
    Car car = new Car("Ferrari", 400);
    System.out.println(car);

    car.sell("Mario Rossi", 1.0E6);
    System.out.println("After selling the car");
    System.out.println(car);

    String brand = car.getBrand();
    int power = car.getHP();
    double price = car.getPrice();
    String owner = car.getOwner();
    boolean sold = car.isSold();
    System.out.println("Information on the car:");
    System.out.println("Brand: " + brand);
    System.out.println("Power: " + power);
    System.out.println("Price: " + price);
    System.out.println("Owner: " + owner);
    System.out.println("Sold:  " + sold);

    car.sell("Carlo Bruni", 100);
    System.out.println("Selling again the car should have no effect");
    System.out.println(car);

  }
}
