Solution for Anagram