• The program consists of a Class customer and the Main function.
• The class customer contains private data items as item value, interest payment, tax payment and total payment.
• The class customer includes two public functions as lease Cal() and lease Show().
• lease Cal() function receives item value and interest rate passed by the main function and set values for item value, interest payment, tax payment and total payment This function calculates interest payment, tax payment and total payment. If the item value is greater than 1000000 then add 2% additional tax for the total payment.
Hint: Interest payment =item value* interest rate.
Tax payment= item value*tax rate
Total Payment=item value + interest amount + tax payment

• The main function is used to ;
-Create objects of customer as piyal, sunil.
-Use object piyal to call lease Cal() passing item value and interest rate.
-Use object piyal to call lease Show() .
-Use object sunil to call lease Cal() passing item value and interest rate.
-Use object sunil to call lease Show().

Recommended Answers

All 3 Replies

• lease Show() function displays item value, interest payment, tax payment and total payment.

Sorry, but we don't do your homework for you (that is cheating). Please make an effort to do the assignment, and we can help you with your mistakes.

:) i like this place... "helping you to learn to code, not to get you the code"

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.