11/13 A Day at the super market


#1

I don't know what's wrong in my code, i have modded it a thousand time and still doesnt work!
A little help please! :smiley:

shopping_list = ["banana", "orange", "apple"]

stock = {
"banana": 6,
"apple": 0,
"orange": 32,
"pear": 15
}

prices = {
"banana": 4,
"apple": 2,
"orange": 1.5,
"pear": 3
}

Write your code below!

def compute_bill(food):
total = 0
for itemz in food:
total = total + prices[itemz]
return total


#2
def compute_bill(food):
    total = 0
    for itemz in food:
        total += prices[itemz]
    return total

Indent your function like this, should work after doing that