题解 | #统计大写字母个数#
统计大写字母个数
http://www.nowcoder.com/practice/434414efe5ea48e5b06ebf2b35434a9c
import string
while True:
try:
s = input()
n = 0
for i in s:
if i in string.ascii_uppercase:
n += 1
print(n)
except:
break
while True:
try:
s = input()
l = [i for i in s if i.isupper()]
print(len(l))
except:
break