anagram has different character order as input