I have a List of dictionaries (a) and i'm trying to iterate through the dictionaries search for a specific value and if the dictionary has that value add that dictionary to a new collection of dictionaries. So far i have
newList = {}
a = [{"one": "green", "two" : "blue", "three" : "red"},
{"two": "blue", "four" : "green", "five" : "yellow"},
{"two": "blue", "six": "white", "seven" : "black"}]
for index in range(len(a)):
if a[index][?] = ["blue"]:
newList.append(a[index])