Added anagram functionality