Pergunta de entrevista da empresa Bijak

Print array elements with there frequency in sorted order O(N)