I have the following dict. I would like to loop through this key and values i.e for items in ice/cold, print "values"
[
{
"ice/cold": [
"vanilla",
"hotchoc",
"mango",
"banana"
]
},
{
"fire/hot": [
"barbecue",
"hotsalsa",
"sriracha",
"kirikiri"
]
},
{
"friendly/mild": [
"ketchup",
"mustard",
"ranch",
"dipster"
]
}
]
Tried this:
data='*above set*'
for key in data.items():
print value
but gives me error
AttributeError: 'list' object has no attribute 'items'