Mathematica 9 is now available
 Documentation / Mathematica / Built-in Functions / Programming / String Manipulation  /
LetterQ

  • LetterQ[ string ] yields True if all the characters in the string are letters, and yields False otherwise.
  • LetterQ[ string ] by default gives False if string contains any space or punctuation characters.
  • LetterQ handles both ordinary and special characters.
  • LetterQ treats as letters all special characters explicitly listed as letters in the table in Section A.12.1.
  • In general, LetterQ treats as letters all characters that appear as ordinary text in any language.
  • LetterQ treats as letters such special characters as , , and æ.
  • LetterQ does not treat as letters (\[EmptySet], ℏ (\[HBar]), (\[Angstrom] or (\[Sum]).
  • See the Mathematica book: Section 2.7.4.
  • See also: DigitQ, UpperCaseQ, LowerCaseQ, CharacterRange.

    Further Examples

    All the characters have to be letters.

    In[1]:=

    Out[1]=

    In[2]:=

    Out[2]=



    Any questions about topics on this page? Click here to get an individual response.Buy NowMore Information
    THIS IS DOCUMENTATION FOR AN OBSOLETE PRODUCT.
    SEE THE DOCUMENTATION CENTER FOR THE LATEST INFORMATION.