import Data.Listimport Control.Arrow frequencies = map (head &&& length) . group . sort main = print $ frequencies "huipizdadjigurda"
Standard input is empty
[('a',2),('d',3),('g',1),('h',1),('i',3),('j',1),('p',1),('r',1),('u',2),('z',1)]
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!