Skip to content

Commit

Permalink
Sol: [BOJ] 10820 문자열 분석
Browse files Browse the repository at this point in the history
  • Loading branch information
k0000k authored Feb 14, 2023
1 parent 52eaeea commit 707f59f
Showing 1 changed file with 25 additions and 0 deletions.
25 changes: 25 additions & 0 deletions String/10820.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
import sys

while (True):
try:
word = input()

small = 0
big = 0
num = 0
space = 0

for i in word:
if (i.isalpha()):
if (97 <= ord(i) <= 122):
small += 1
else:
big += 1
elif (i.isdigit()):
num += 1
else:
space += 1

print(small, big, num, space)
except:
sys.exit()

0 comments on commit 707f59f

Please sign in to comment.