python collections package code example Example: python collections list = [1,2,3,4,1,2,6,7,3,8,1] Counter(list)