题解 | #使用字典计数#
使用字典计数
https://www.nowcoder.com/practice/74f7e7f2344f4754bc56d862838cbfc3
word = input()
d = {}
for i in word:
if i not in d:
d[i] = 1
else:
d[i] += 1
print(d)
使用字典计数
https://www.nowcoder.com/practice/74f7e7f2344f4754bc56d862838cbfc3
word = input()
d = {}
for i in word:
if i not in d:
d[i] = 1
else:
d[i] += 1
print(d)
相关推荐
饼子吃到撑:现在就是学历大于一切了,尤其是应届生,你再厉害人家筛选按钮选择985双非直接完蛋,学历就是硬伤,公司肯定都想用优秀的人,但是不知道你到底优不优秀只能通过最原始的方法来筛选~学历,