Counter class for Python < 2.7
Copied verbatim from Python 2.7 collections module. Tested in Python 2.6, but not in 2.5, although I've checked the docs, and it shouldn't rely on anything that's not in 2.5.
