IsAnagram - Maple Help

StringTools

 IsAnagram
 test whether one string is an anagram of another

 Calling Sequence IsAnagram( s, t )

Parameters

 s - string t - string

Description

 • The IsAnagram(s,t) command returns the value true if the string s is an anagram (permutation) of the string t. Otherwise, the value false is returned.
 • If s and t are empty strings, the command returns true.
 • All of the StringTools package commands treat strings as (null-terminated) sequences of $8$-bit (ASCII) characters.  Thus, there is no support for multibyte character encodings, such as unicode encodings.

Examples

 > $\mathrm{with}\left(\mathrm{StringTools}\right):$
 > $\mathrm{IsAnagram}\left("elvis","lives"\right)$
 ${\mathrm{true}}$ (1)
 > $\mathrm{IsAnagram}\left("diet","edit"\right)$
 ${\mathrm{true}}$ (2)
 > $\mathrm{IsAnagram}\left("tide","diet"\right)$
 ${\mathrm{true}}$ (3)
 > $\mathrm{IsAnagram}\left("tide","toad"\right)$
 ${\mathrm{false}}$ (4)
 > $\mathrm{IsAnagram}\left("the eyes","they see"\right)$
 ${\mathrm{true}}$ (5)
 > $\mathrm{IsAnagram}\left("eleven plus two","twelve plus one"\right)$
 ${\mathrm{true}}$ (6)