2.7.4 Characters in Strings
This gives a list of the characters in the string.
Converting between strings and lists of characters.
In:= Characters["A string."]
You can apply standard list manipulation operations to this list.
In:= RotateLeft[%, 3]
StringJoin converts the list of characters back to a single string.
All characters in the string given are letters.
Testing characters in a string.
Not all the letters are upper case, so the result is False.
This converts all letters to upper case.
Converting between upper and lower case.
In:= ToUpperCase["Mixed Form"]
This generates a list of lower-case letters in alphabetical order.
Generating ranges of characters.
In:= CharacterRange["a", "h"]
Here is a list of upper-case letters.
In:= CharacterRange["T", "Z"]
Here are some digits.
In:= CharacterRange["0", "7"]
CharacterRange will usually give meaningful results for any range of characters that have a natural ordering. The way CharacterRange works is by using the character codes that Mathematica internally assigns to every character.
This shows the ordering defined by the internal character codes used by Mathematica.
In:= CharacterRange["T", "f"]