Amazon interview question

Group anagrams inside an array.