华为机试HJ84统计大写字母个数 题目: 统计输入字符串中大写字母的个数 想法: 遍历整个字符串,记录大写字母的个数 input_str = input() count = 0 for i in input_str: if i >= "A" and i <= "Z": count += 1 print(count)