Domanda di colloquio di OYO

Sort an array based on frequency of its elements.