Please help me find out what’s wrong?
Here is the error:
“calling compute_bill with a list containing 1 apple, 1 pear and 1 banana resulted in 4 instead of the correct 7”
# Write your code below! def compute_bill(food): total = 0 for x in food: if stock[x] > 0: total = total + prices[x] stock[x] = stock[x] - 1 return total