I need help with my first assignment regarding classes.
I have no clue where to start so if possible could you please walk me through the best logical process to solve this assignment. I have no clue where to start so any information will help.
Here is what I need to do:
I need to define a class called odometer.
This class will track fuel and mileage for a car.
The class should have member variables to track the miles driven and the fuel efficiency of the car in miles per gallon.
Include a mutator function to reset the odometer to zero miles, a mutator function to set the fuel efficiency, a mutator function that accepts miles driven for a trip and adds it to the odometer's total, and an accessor function that returns the number of gallons of gas that the vehicle has consumed since the odometer was last reset.
Use your class with a test program that creates several trips with different fuel efficiencies. You decide which variables should be public if any.
I really have no idea where to start, please talk to me like a 2 year old because basically I am in C++.
I am not asking you to do the assignment I am asking for you to tell me how to do it/ what do do.
Thank you very much.