4 ms·
I think rgarcia was talking about defaultdict and friends, see http://docs.python.org/library/collections.html#collections.defaultdict http://docs.python.org/li
by gcr 16y ago
I think rgarcia was talking about defaultdict and friends, see http://docs.python.org/library/collections.html#collections.defaultdict http://docs.python.org/library/collections.html#collections....
Classes that implement __getitem__ can behave however they want when you use brackets on them. See http://docs.python.org/reference/datamodel.html#object.__getitem__ http://docs.python.org/reference/datamodel.html#object.__get...