I'm having trouble with a problem that someone might hopefully be able to suggest an answer to.
I need to iterate over a list of words, and count the number of words that are "the same" based only on letter content. For example, if the word array contains "opt", "top", "pot", "pit" and "tip" then that would count of three instances of one "word" containing o, p and t and two instances of one "word" containing p, i and t.
Presumably some sort of hash storing the first occurrence of a unique word as a key with counts as a value, matching new words against all the keys and incrementing the value would be a way of doing it, but I'm not sure how to go about comparing the new words to the hash keys. Can anyone offer a suggestion, or suggest any other means of doing this?