is alpha:

  • In python "is alpha" is the method used to check the alphabets whether they are present in the given string or substring.
  • In isalpha, it must carry only alphabets.
  • It carries the result in the boolean type
  • If the string contains all alphabets then it returns true, else false.
  • The isalpha is not applicable for the alphanumeric.
  • It is the built-in function of python.
syntax: str.isalpha()

Example:  s="abcdefg"
                   str.isalpha(s)
                    true

#write a python program to demonstrate is alpha function.

  1. a="india"
  2. b="india123"
  3. a=str.isalpha(a)
  4. b=str.isalpha(b)
  5. print(a)
  6. print(b)
output: true
             false


Instance Of Java

We will help you in learning.Please leave your comments and suggestions in comment section. if you any doubts please use search box provided right side. Search there for answers thank you.
«
Next
Newer Post
»
Previous
Older Post

No comments

Leave a Reply

Select Menu