0
I cannot continue
Calculate and display the retail price for product registration until user enter a negative wholesale cost. Retail price = wholesale price * 0.25 Store all retail price list and print out a price list in table format. What I have is below: retail_price = 0 while (True): wholesale_cost = int(input("Enter your wholesale cost:")) if (wholesale_cost < 0): break else: retail_price = wholesale_cost * 0.25 print(retail_price)
2 Réponses
+ 7
You just need to add a list variable, like prices = [] and append retail_price to it, each time it is calculated.
Then, when the loop is broken, print out this list.
- 2
it will be a very nice price list without products names))))