subject

I need to adapt this program so that the user has the ability to order multiple orders using a for loop or while loop, I will give brainliest to anybody with a good answer or help with this! (This is Python, You can use Trinket. io to edit the code)

Fries_Bought = False
Sandwhich_Bought = False
Beverage_Bought = False
Total_Cost = 0
order = []
Discounts = "You didn't get any discounts :("
print ("Combo Menu")
print ("Item 1: chicken $5.25")
print ("Item 2: beef $6.25")
print ("Item 3: tofu $5.75")
Sandwhich = input("Which Sandwhich Would You Like? Insert Meat Name:")
if Sandwhich == "Chicken":
order. append("Chicken")
Total_Cost = Total_Cost + 5.25
Sandwhich_Bought = True
if Sandwhich == "Beef":
order. append("Beef")
Total_Cost = Total_Cost + 6.25
Sandwhich_Bought = True
if Sandwhich == "Tofu":
order. append("Tofu")
Sandwhich_Bought = True
Total_Cost = Total_Cost + 5.75
Beverage = input("Would you like a beverage? (Small, Medium, Large, or none)")
if Beverage == "Small":
Total_Cost = Total_Cost + 1
Beverage_Bought = True
order. append("Small Beverage")
if Beverage == "Medium":
Total_Cost = Total_Cost + 1.75
Beverage_Bought = True
order. append("Medium Beverage")
if Beverage == "Large":
Total_Cost = Total_Cost + 2.25
Beverage_Bought = True
order. append("Large Beverage")
Fries = input("What size of fries would you like? (Small, Medium, Large, None)")
if Fries== "Small":
Mega = input("Would you like to mega size?")
if Mega == "Yes":
Total_Cost = Total_Cost + 2
Fries_Bought = True
order. append("Mega Fries")
if Mega == "No":
Total_Cost = Total_Cost + 1
Fries_Bought = True
order. append("Small Fries")
if Fries == "Medium":
Total_Cost = Total_Cost + 1.5
Fries_Bought = True
order. append("Medium Fries")
if Fries == "Large":
Total_Cost = Total_Cost + 2
Fries_Bought = True
order. append("Mega Fries")
if Fries == "None":
Total_Cost = Total_Cost + 0
Ketchup = input("How Many Ketchup Packets do you want? (Up to 25 Ketchup Packets)")
if Ketchup == "1":
Total_Cost = Total_Cost + 0.25
order. append("1 Ketchup")
if Ketchup == "2":
Total_Cost = Total_Cost + 0.50
order. append("2 Ketchup")
if Ketchup == "3":
Total_Cost = Total_Cost + 0.75
order. append("3 Ketchup")
if Ketchup == "4":
Total_Cost = Total_Cost + 1
order. append("4 Ketchup")
if Ketchup == "5":
Total_Cost = Total_Cost + 1.25
order. append("5 Ketchup")
if Ketchup == "6":
Total_Cost = Total_Cost + 1.5
order. append("6 Ketchup")
if Ketchup == "7":
Total_Cost = Total_Cost + 1.75
order. append("7 Ketchup")
if Ketchup == "8":
Total_Cost = Total_Cost + 2
order. append("8 Ketchup")
if Ketchup == "9":
Total_Cost = Total_Cost + 2.25
order. append("9 Ketchup")
if Ketchup == "10":
Total_Cost = Total_Cost + 2.5
order. append("10 Ketchup")
if Ketchup == "11":
Total_Cost = Total_Cost + 2.75
order. append("11 Ketchup")
if Ketchup == "12":
Total_Cost = Total_Cost + 3
order. append("12 Ketchup")
if Ketchup == "13":
Total_Cost = Total_Cost + 3.25
order. append("13 Ketchup")
if Ketchup == "14":
Total_Cost = Total_Cost + 3.5
order. append("14 Ketchup")
if Ketchup == "15":
Total_Cost = Total_Cost + 3.75
order. append("15 Ketchup")
if Ketchup == "16":
Total_Cost = Total_Cost + 4
vorder. append("16 Ketchup")
if Ketchup == "17":
Total_Cost = Total_Cost + 4.25
order. append("17 Ketchup")
if Ketchup == "18":
Total_Cost = Total_Cost + 4.5
order. append("18 Ketchup")
if Ketchup == "19":
Total_Cost = Total_Cost + 4.75
order. append("19 Ketchup")
if Ketchup == "20":
Total_Cost = Total_Cost + 5
order. append("20 Ketchup")
if Ketchup == "21":
Total_Cost = Total_Cost + 5.25
order. append("21 Ketchup")
if Ketchup == "22":
Total_Cost = Total_Cost + 5.5
order. append("22 Ketchup")
if Ketchup == "23":
Total_Cost = Total_Cost + 5.75
order. append("23 Ketchup")
if Ketchup == "24":
Total_Cost = Total_Cost + 6
order. append("24 Ketchup")
if Ketchup == "25":
Total_Cost = Total_Cost + 6.25
order. append("25 Ketchup")
if Sandwhich_Bought == False:
order. append("No Sandwhich Bought")
if Beverage_Bought == False:
order. append("No Beverage Bought")
if Fries_Bought == False:
order. append("No Fries Bought")
if Sandwhich_Bought == True:
if Beverage_Bought == True:
if Fries_Bought == True:
Total_Cost = Total_Cost - 1
Discounts = "You got 1.00 off your order!"
print ("You have chosen for your meal:")
print (Sandwhich)
print ("You have chosen for your Beverage:")
print (Beverage)
print ("You have chosen for your Fries:")
print (Fries)
print ("You have chosen for your Ketchup Packets:")
print (Ketchup)
print (Discounts)
print ("Your total is:")
print (Total_Cost)
print (order)

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 21.06.2019 22:40
State the parts of a variable declaration?
Answers: 2
question
Computers and Technology, 22.06.2019 04:30
Which of the statements below is true? the formatting, standard, and drawing commands are unavailable. the formatting, standard, and drawing commands have been used. the formatting, standard, and drawing toolbars are displayed. the formatting, standard, and drawing toolbars are hidden.
Answers: 1
question
Computers and Technology, 22.06.2019 16:10
When copying and pasting text, the first step is move your cursor type the text select the copy command select the paste command
Answers: 2
question
Computers and Technology, 22.06.2019 17:40
Gabe wants to move text from one document to another document. he should copy the text, paste the text, and open the new document highlight the text, select the cut command, move to the new document, make sure the cursor is in the correct location, and select the paste command select the save as command, navigate to the new document, and click save highlight the text, open the new document, and press ctrl and v
Answers: 1
You know the right answer?
I need to adapt this program so that the user has the ability to order multiple orders using a for l...
Questions
question
Mathematics, 09.01.2020 06:31