Python program to print all alphabets from a to z; In this tutorial, i will show you how to print all alphabets from a to z in python.
Python Program to Print Alphabets from A to Z
Now, i will write and show you some python program to print alphabets and from a to z and check whether a given input is alphabet or not; as shown below:
- 1: Write a python program to print all alphabets from a to z using for loop
- 2: Python program to print a to z in alphabets in lowercase using for loop
- 3: write a program to check whether the given input is alphabet or not in python
1: Write a python program to print all alphabets from a to z using for loop
# write a python program to print alphabets in uppercase from a to z print("Uppercase Alphabets are:") for i in range(65,91): ''' to print alphabets with seperation of space.''' print(chr(i),end=' ')
Output
Uppercase Alphabets are: A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
2: Python program to print a to z in alphabets in lowercase using for loop
# write a python program to print alphabets in lowercase from a to z print("\nLowercase Alphabets are:") for j in range(97,123): print(chr(j),end=' ')
Output
Lowercase Alphabets are: a b c d e f g h i j k l m n o p q r s t u v w x y z
3: write a program to check whether the given input is alphabet or not in python
# Python Program to Check Alphabet ch = input("Enter a character: ") if((ch>='a' and ch<= 'z') or (ch>='A' and ch<='Z')): print(ch, "is an Alphabet") else: print(ch, "is not an Alphabet")
Output
Enter a character: 4 4 is not an Alphabet
Recommended Python Tutorials
Recommended:-Python Program to Find Largest of n Numbers
Recommended:-Python Program to Find Power of Number
Recommended:-Python Program to Print Prime Number From 1 to N
Recommended:-Python Program to Find Square Root of Number
Recommended:-Python Program to Find Cube of Number
Recommended:-Python Palindrome Program
Recommended:-Python Program to Count Set Bits in a Number
Recommended:-Python Program for BMI Calculation
Recommended:-Python Program to Find Out Absolute Value
Recommended:-Python Random Number Generator Code
Recommended:-Python program for Zip, Zap and Zoom game
Recommended:-Python Program to Swap Two Numbers
Recommended:-Python Program to Find n-th term of Fibonacci Series
Recommended:-Python Program For Calculator
Recommended:-Python Program to Find Strong Number
Recommended:-Python Program to Convert cm to Feet and Inches
Recommended:-How to Reverse a List in Python
Recommended:-Python Program to Convert Celsius to Fahrenheit
Recommended:-Python Program to Find Standard Deviation
Recommended:-Python Program to Check Perfect Number
Recommended:-Python Program to Display Calendar