Combining?
So I can use: newlist = sorted(items, key =items.count, reverse = True) Which doesn't group them by index, or I can use: newlist = sorted(items, key =lambda x: (items [x], x), reverse = True) Which groups everything, but not by frequency. What is the easiest way to combine the two? Someone suggested trying to index them, but since I don't have much experience in python, it becomes all guess and check.