Keepin track orange ish


it tells me orange is printing out wrong

I expect it to work just fine

    "banana" : 4, "apple" : 2,   "pear" : 3, "orange" : 1.5
stock = {
    "banana" : 6,  "apple" : 0,      "pear" : 15, "orange" : 32
for key in prices:
    print key
    print "prices : %s" % prices[key]
    print "stock : %s" % stock[key]    

please what is the problem


prices needs to be price, and you need to get rid of the space between price and the colon, :


thanks a lot that did it. have a splendid day


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

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

for key in price:
print key
print "Price: %s" % price[key]
print "Stock: %s" % stock[key]

The explanation above doesn't solve the issue for me @kyleaw , any idea please?
It keeps saying: Oops, try again. Check what your code prints for orange. It doesn't look quite right!


price and stock need to be lowercase


Ok.. thanks alot for your reply.

This solved my problem, but when I returned both to uppercase, it still worked, tho it didnt work earlier...

So, I guess its proly something wrong with the compiler.



So, I tried it again, and and it threw back and error.. so guess youre so right.