summaryrefslogtreecommitdiff
path: root/progs/unparsable_programs/a662.py
blob: 0ab4afbc5558ed5eedeaca63e5977c80ed546780 (plain)
1
2
3
4
5
6
from collections import defaultdict
def max_aggregate(stdata):
    temp = defaultdict(int)
    for name, marks in stdata:
        temp[name] += marks
    return max(temp.items(), key=lambda x: x[1])