This is supposed to take the number for each item in prices and multiply it with the number for each item in stock to get the total cost. It doesn't work though and I can't figure out why.
total = 0
for food in prices:
total = prices[food] * stock[food]