Computer Science, asked by anilanimesh901, 9 months ago

An electronics shop has announced the following seasonal discounts on the purchase of certain items. Purchase amount in Rs. Discount on Laptop Discount on Desktop 0-25000 0.0% 5.0% 25001-57000 5.0% 7.5% 57001-100000 7.5% 10.0% More than 100000 10.0% 15.0% Write a Program based on the above criteria to input name, address, amount of purchase and type of purchase(L for Laptop and D for Desktop) by the customer. Calculate and print the net amount to be paid by a customer along with his/her name and address. [Use ternary operator to calculate discount on Laptop or Desktop] Hint: (discount=( discount rate/100)*amount of purchase) (Net amount= amount of purchase – discount)

Answers

Answered by devishashi799
2

Answer:

An electronics shop has announced the following seasonal discounts on the purchase of certain items.

Purchase Amount in Rs. Rs. Discount on Laptop Discount on Desktop P

0—25000 0.0% 5.0%

25001—57000 5.0% 7.5%

57001—100000 7.5% 10.0%

More than 100000 10.0% 15.0%

Write a program based on the above criteria, to input name, address, amount of purchase and the type of purchase (L for Laptop and D for Desktop) by a customer. Compute and print the net amount to be paid by a customer along with his name and address.

(Hint : discount = (discount rate! 100)* amount of purchase Net amount = amount of purchase – discount)

Similar questions