题解 | 字符个数统计

字符个数统计

https://www.nowcoder.com/practice/eb94f6a5b2ba49c6ac72d40b5ce95f50

import collections
import sys

s_in = input()
d = collections.defaultdict(int)
for x in s_in:
    if x >="!" and x <= "~":
        d[x] += 1
print(len(d.items()))

全部评论

相关推荐

03-11 10:06
已编辑
河南师范大学 C++
点赞 评论 收藏
分享
评论
点赞
收藏
分享

创作者周榜

更多
牛客网
牛客企业服务