Answered step by step
Verified Expert Solution
Question
1 Approved Answer
In JAVA: In this assignment you will create a program that describes an automobile. Here are the parameters: Car Year Car Make Car Model Car
In JAVA:
In this assignment you will create a program that describes an automobile. Here are the parameters:
Car Year
Car Make
Car Model
Car Color
Top Speed of the Car
You will create the class, then call a single instance of the class. The output is simply the properties of the object you have created in the class.
Styles Paragraph import java.io. Printstreami public class CarClass public static void main(Strinet] args) 14 Car carl new Car (2015, Red "Nissan "GTR 196) 16 System.out.println("The carl get year() car 1. get Color( carl get Make() carl get Model() s speed is Carl mph."); Car dass 33 Caraass dass public class Car private int carYear private String carColon private String carMake private String c private int carSpeed; public Carint year, String color, String make, String model int speed) this sarColor color this sarake makes this sarModel model this carYear. year this sar Speed speed public int getYear() return this sacYear; public String getColor() 31 return this public string getMake() e 34 return this SADMaksi public String getModel() e return this cacKodelu public int getspeedC) return this saesReedu 40
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started