Question: IN C# PLEASE Complete the Programming Challenge #2 Car Class on Page 602. Make sure to use proper naming conventions, include the header comments and

IN C# PLEASE

Complete the Programming Challenge #2 Car Class on Page 602. Make sure to use proper naming conventions, include the header comments and comments for each click event outlining what the code is doing.

Car Class Create a class named Car that has the following properties: YearThe Year property holds the cars year model. MakeThe Make property holds the make of the car. SpeedThe Speed property holds the cars current speed. In addition, the class should have the following constructor and other methods: ConstructorThe constructor should accept the cars year and model and make them as arguments. These values should be assigned to the backing fields for the objects Year and Make properties. The constructor should also assign 0 to the backing field for the Speed property. AccelerateThe Accelerate method should add 5 to the Speed propertys backing field each time it is called. BrakeThe Brake method should subtract 5 from the Speed propertys backing field each time it is called. Demonstrate the class in an application that creates a Car object. The applications form should have an Accelerate button that calls the Accelerate method and then displays the cars current speed each time it is clicked. The applications form should also have a Brake button that calls the Brake method and then displays the cars current speed each time it is clicked.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!