I am looking for a fast and efficient way to calculate the frequency of list
items in python:
list = ['a','b','a','b', ......]
I want a frequency counter which would give me an output like this:
[ ('a', 10),('b', 8) ...]
The items should be arranged in descending order of frequency as shown above.
Python2.7+
python2.5/2.6