SyntaxFix
Write A Post
Hire A Developer
Questions
from collections import Counter most_common,num_most_common = Counter(L).most_common(1)[0] # 4, 6 times
For older Python versions (< 2.7), you can use this recipe to create the Counter class.
Counter