summaryrefslogtreecommitdiff
path: root/progs/a52.py
blob: 131af011baffd01ead0746fd52a230fada92c352 (plain)
1
2
3
4
5
6
7
8
from collections import defaultdict


def grouping_dictionary(l):
    d = defaultdict(list)
    for k, v in l:
        d[k].append(v)
    return d