Skip to content

Commit 775c151

Browse files
authored
Find no. of Upper Case Letters and Lower Case Letters.py
This is a Python Program to Calculate the Number of Upper Case Letters and Lower Case Letters in a String.
1 parent 7d5818c commit 775c151

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
string=raw_input("Enter string:")
2+
count1=0
3+
count2=0
4+
for i in string:
5+
if(i.islower()):
6+
count1=count1+1
7+
elif(i.isupper()):
8+
count2=count2+1
9+
print("The number of lowercase characters is:")
10+
print(count1)
11+
print("The number of uppercase characters is:")
12+
print(count2)

0 commit comments

Comments
 (0)