多应用+插件架构,代码干净,二开方便,首家独创一键云编译技术,文档视频完善,免费商用码云13.8K 广告
>[success] Counter 统计列表中出现次数 ~~~ from collections import Counter words = [ "look", "into", "my", "eyes", "look", "into", "my", "eyes", "the", "eyes", "the", "eyes", "not", "around" ] print(Counter(words)) 打印结果: Counter({'eyes': 4, 'my': 2, 'into': 2, 'look': 2, 'the': 2, 'around': 1, 'not': 1}) ~~~