10 ms·
This is not correct (try returning a defaultdict). That is the reason that Python 3.6 added a new inline type hint syntax My_dict: defaultdict[int, List[in
by gglanzani 10y ago
This is not correct (try returning a defaultdict). That is the reason that Python 3.6 added a new inline type hint syntax
My_dict: defaultdict[int, List[int]] = defaultdict(int)