Computer Science, asked by uditapandit2020, 3 months ago

An organization called Rent -a-car allows customers to rent a car for maximum of 15 days.

Design a class called CarRent with the following description :

Instance variables / data members

carnum : to store the car’s number

mobnum : to store the mobile number of the customer

name : to store the name of the customer

days : to store the number of days the car is taken on rent

charge : to calculate and store the rental charge

Member methods

void input( ) : to input and store the details of the customer

void compute ( ): to compute the rental charge on the following basis -

Number of days Charge per day

First 5 days 3000/-

Next 5 days 2000/-

Rest of the days 1500/-

void display( ) : to display the details in the following format -

Car No. Mobile No. Name Number of days Charge

--- ----- ---- ------- ----

Create a main method to invoke the member methods of the class.​

Answers

Answered by vikashmishra35
0

Answer:

coming do it for me to you f u u cut

Similar questions