Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR TYPESCRIPT

how to check if a string is composed only of alphabets in python

str1 = "hello world. welcome to python examples."

bool = str1.isalpha()

print('str1 contains only alphabets:', bool)
//output will be False
 
PREVIOUS NEXT
Tagged: #check #string #composed #alphabets #python
ADD COMMENT
Topic
Name
8+1 =