Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- text = input()
- lenght = len(text)
- count_lower = 0
- count_upper = 0
- for i in range(lenght):
- if (text[i].islower()):
- count_lower += 1
- elif (text[i].isupper()):
- count_upper += 1
- count_all = count_lower + count_upper
- proc_upper = count_upper * 100 / count_all
- proc_lower = count_lower * 100 / count_all
- print(f"{proc_upper:.2f}%")
- print(f"{proc_lower:.2f}%")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement