Question: This is the code for the driver. This is NOT meant to be modified! import java.util.Scanner; //A class that keeps a fleet of different types



![private Vehicle[] fleet; public static final int MAX_VEHICLES = 100; public FleetOfVehicles()](https://dsd5zvtm8ll6.cloudfront.net/si.experts.images/questions/2024/09/66f0f5fcd47bf_64466f0f5fc7397e.jpg)
![{ fleet = new Vehicle[MAX_VEHICLES]; } public Vehicle[] getFleet() { return this.fleet;](https://dsd5zvtm8ll6.cloudfront.net/si.experts.images/questions/2024/09/66f0f5fd75ff6_64566f0f5fd17976.jpg)



This is the code for the driver. This is NOT meant to be modified!
import java.util.Scanner; //A class that keeps a fleet of different types of vehicles public class FleetOfVehicles { //An array of vehicles private Vehicle[] fleet; public static final int MAX_VEHICLES = 100; public FleetOfVehicles() { fleet = new Vehicle[MAX_VEHICLES]; } public Vehicle[] getFleet() { return this.fleet; } //Adds a new vehicle to the first empty spot in the fleet array public void addVehicle(Vehicle aV) { for(int i=0;i Objective: Write a classes that represents a vehicle svstem First download the driver and put it in your project DO NOT ALTER THE DRIVER! Write a class file called Vehicle . Some of the attributes are Manufacturer's name o Number of Cylinders (must be greater than 0) Owner's name . Create the following Constructors Default - sets everything to default values o Parameterized Constructor Check for valid values Accessors and Mutators for each variable o MAKE SURE THE MUTATORS CHECK FOR VALID VALUES! . Create the following Methods o equals - takes in another instance of a Vehicle and returns true only if the names and the number of cylinders are equal tostring-returns a String that contains the Manufacturer's name, number of cylinders, and the owners name Write another class Truck which is a Vehicle . Some of the attributes of Truck are o Load capacity: a nonnegative number of tons represented by a decimal number o Towing capacity: a nonnegative number of tons represented by a decimal . Create the following constructors Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
