I have seen some similar answers, but I can't find something specific for this case:
I have a list of dictionaries like this:
[
{"element":Bla, "version":2, "date":"12/04/12"},
{"element":Bla, "version":2, "date":"12/05/12"},
{"element":Bla, "version":3, "date":"12/04/12"}
]
The actual dictionary has many other keys, but what I'm trying to do is to delete all the entries that have the exact same key pair values, except for the date. That is, to delete all duplicates (which are not really exact duplicates as only the date varies). In this case, what I would expect to get is:
[
{"element":Bla, "version":2, "date":"12/04/12"},
{"element":Bla, "version":3, "date":"12/04/12"}
]
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…