Riverbed interview question

anagram question and how to implement it multiple ways