July 28, 2014
11:13 p.m.
Alexander Heger writes:
I mistyped. It should have read " ... the behaviour in place for collections.Counter"
But there *is* a *the* (ie, unique) "additive" behavior for Counter. (At least, I find it reasonable to think so.) What you're missing is that there is no such agreement on what it means to add dictionaries. True, you can "just pick one". Python doesn't much like to do that, though. The problem is that on discovering that dictionaries can be added, *everybody* is going to think that their personal application is the obvious one to implement as "+" and/or "+=". Some of them are going to be wrong and write buggy code as a consequence.