哈利路亚
Let's take one million years picnic
欢迎来到Sean Cleveland的博客
软工超越日报-顶会热词词频分解 5/4

今天是五四青年节……结果还是建民课……

那么还是个人作业,来分解统计词频吧:

fen_cil = fen_ci.lower().split()
dic = {}
for word in fen_cil:
    if word not in dic:
        dic[word] = 1
    else:
        dic[word] = dic[word] + 1
swd = sorted(dic.items(),key=operator.itemgetter(1),reverse=True)

我们将标题写成一个大号字符串,之后进行分词

最终效果就是这样:

 

posted on 2021-05-04 20:14  哈利路亚#0207  阅读(32)  评论(0编辑  收藏  举报
Live2D