Append a new value to dict

Frank Niemeyer frank.niemeyer at uni-ulm.de
Thu Oct 23 09:47:25 CEST 2008


bearophileHUGS at lycos.com schrieb:
> Frank Niemeyer:
>> There's simply no
>> way to increment a non-existent value - not without performing some
>> obscure implict behind-the-scenes stuff.
> 
> Like importing and using a defaultdict(int).

There's nothing implicit in explicitly defining some default behaviour.

Frank




More information about the Python-list mailing list