Actually, collections.Counter do just that. Count the characters. Don't know for non printable ones.
I have somewhere a piece of code I've wrote for a yet unfinished project during my basic Python learning. It counts and sort by decr. frequency
Didn't know the collections module that time
I have somewhere a piece of code I've wrote for a yet unfinished project during my basic Python learning. It counts and sort by decr. frequency
Didn't know the collections module that time