name_list = [{'name': 'John'}, {'name': 'Johan'}, {'name': 'John'}]
for i in xrange(len(name_list)):
if name_list[i]["name"] == "John":
del name_list[i]
After the first time recognizing John, it deletes that object but breaks out of the function. How can I continue traversing till the end and delete every single JSON object which has John as name?
Many thanks guys!