Question: Hello, please i need a simple code for this java program using scanner or joptionpane Probleml: Write the classes implementations for the following classes' specifications.

Hello, please i need a simple code for this java program using scanner or joptionpane
Probleml: Write the classes implementations for the following classes' specifications. Registered Vehicle year: an integer to indicate the registration year. Attributes plNum: A String to indicate the license plate number. type: an integer that can have the value 1 (private) or 2 (public). Constructor .toString: to return information about a registered vehicle. Methods getType: returns the type of a registered vehicle. Car is a registered vehicle brand: a string of characters to store the car brand name. color: a string of characters. Attributes model: an integer to specify the car model number. cost: a number to indicate the car basic cost. totalPrice: It should accumulate the value of all cars' prices. Constructor. calculate Price: returns the price of a car using the following formula: o Price = cost + 300$ if type = 1. Price = cost + 200$ if type = 2. Methods getTotalPrice: returns the value of totalPrice. toString: to print the information about a car as follows: Mercedes-red-300 (08) - (123456) was registered in 2010 and is a private vehicle. Price = $12500. Write an application to test your classes' implementations
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
