Working on one of the homework, and I am having and issue writing the logic. I want to identify the minimum score for type homework and drop it based on the '_id' for that document. Here is what I have so far but I am having trouble extracting the _id. Any help would be great i am very new to this.
db.grades.find({'id': {'type': 'homework', 'score': {$min : 'score'}}})