String Methods

str.isalpha()

Test for a nonempty string made exclusively of Unicode Letter general categories (Lm, Lt, Lu, Ll, Lo). This is narrower than the Unicode Alphabetic derived property. Precomposed accented letters can pass while a decomposed spelling containing a combining mark fails. It is not a complete human-name validator. Takes no arguments.

Formal Syntax & Structure

python syntaxpython
text.isalpha()

Return Value

bool

True when the stated classification holds; otherwise False.

Working Example

Example Snippetpython
for text in ("Sara", "سلام", "é", "e\u0301", "Sara 2"):    print(ascii(text), text.isalpha())
Python Reference