Question: efine a default constructor that initializes the data members, char weekendPrice, integer mileage, and string renter, with the default values ' N ' , -

efine a default constructor that initializes the data members, char weekendPrice, integer mileage, and string renter, with the default values 'N',-1, and "Unspecified", respectively.
Ex: If the input is Y 80000 Bob, then the output is:
Weekend price: N, Mileage: -1, Renter: Unspecified Weekend price: Y, Mileage: 80000, Renter: Bob
Note: The class's print function is called first after the default constructor, then again after the inputs are passed to the setters.
C++

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 Programming Questions!