Use a hash map with key being the sorted word and value being a vector of strings of all instances of that anagram. Iterate through input array, filling the hash map. Then iterate through the hash map adding the map values (vectors) to our result vector.
