Anagram ordering