Write a class called Product. The class should have fields called name, stock-items, and price, holding the product’s name, the number of items of that product in stock, and the regular price of the product. There should be a method get_price that receives the number of items to be bought and returns the cost of buying that many items, where the regular price is charged for orders of less than 10 items. There should also be a method called make_purchase that receives the number of items to be bought and returns the decreased amount by that much. As a 10% discount is applied for orders of between 10 and 99 items, and a 20% discount is applied for orders of 100 or more items.
Moreover, get additional marks for:
1. Add more functionality in the identified class.
2. Design a user friendly interface for given task.
1
Expert's answer
2020-08-24T01:48:18-0400
Dear Rashid, your question requires a lot of work, which neither of our experts is ready to perform for free. We advise you to convert it to a fully qualified order and we will try to help you. Please click the link below to proceed: Submit order
Numbers and figures are an essential part of our world, necessary for almost everything we do every day. As important…
APPROVED BY CLIENTS
"assignmentexpert.com" is professional group of people in Math subjects! They did assignments in very high level of mathematical modelling in the best quality. Thanks a lot
Comments
Leave a comment