C# Programming Challenge: OOP Principles Part 1 – Creating Car Class, C# Fields and C# Class Methods

Share it with your friends Like

Thanks! Share it with your friends!

Close

C# How to Program

1. Implement a Car class which has fields to store the car’s make, model, registration, year (of initial registration), and current value.
2. Implement a constructor for the Car class which takes parameters corresponding to each of the fields above and constructs an object with these values.
3. Implement a C# Class methods which returns the current value of the car
4. Implement a method which returns the year of the car
5. Override ToString to return a string containing full information about the car
6. Write a test class which constructs a Car and prints its details to the console

DOWNLOAD SOURCE CODE: yt_car_fleetcar

Comments

Write a comment

*