Programming Examples

Python program to check character is alphabetic character or not


Write a Python program to  check character is alphabetic character or not

Solution

ch=input("Enter any alphabetic character : ")
if ch>='A' and ch<='Z':
    print("The Character is an upper case letter")
elif ch>='a' and ch<='z':
    print("The Character is an lower case letter")
else:
    print("This is not an alphabetic character!")
▶ RUN

Output/ Explanation:

Enter any alphabetic character : f

The Character is an lower case letter

>>> 

======================== 

Enter any alphabetic character : R

The Character is an upper case letter

>>> 

======================== 

Enter any alphabetic character : 4

This is not an alphabetic character!

>>> 

======================== 

Enter any alphabetic character : #

This is not an alphabetic character!

>>> 

Latest Current Affairs 2025 Online Exam Quiz for One day Exam Online Typing Test CCC Online Test Python Programming Tutorials Best Computer Training Institute in Prayagraj (Allahabad) Online MBA 2 years Online MCA Online BCA Best Website and Software Company in Allahabad