public class Car { private int year; private String make; private String model; private int numDoors; private CarType type; private double value; private double mileage; private boolean electric; // there is only 1 for all objects to share private static int numCars = 0; public Car() { year = 2025; make = ""; model = ""; numDoors = 0; type = CarType.Sedan; value = 0.0; mileage = 0.0; electric = false; numCars++; } public Car(int year, String make, String model) { this.year = year; this.make = make; this.model = model; this.numDoors = 0; this.type = CarType.Sedan; this.value = 0.0; this.mileage = 0.0; this.electric = false; numCars++; } public Car(int year, String make, String model, int numDoors, CarType type, double value, double mileage, boolean electric) { this.year = year; this.make = make; this.model = model; this.numDoors = numDoors; this.type = type; this.value = value; this.mileage = mileage; this.electric = electric; numCars++; } public double getMileage() { return mileage; } public void setMileage(double mileage) { this.mileage = mileage; } public void print() { System.out.println(year + " " + make + " " + model); } public static int getNumCars() { return numCars; } }