Skip to content

Commit 390a584

Browse files
authored
Merge pull request selfteaching#1536 from 11661246/master
19100205 11day
2 parents 2c39b5b + fd1bb7e commit 390a584

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

19100205/11661246/d11_training1.py

+8-4
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,7 @@
33
import requests
44
from pyquery import PyQuery
55

6-
# -*- coding: utf-8 -*-
7-
response = requests.get('https://mp.weixin.qq.com/s/pLmuGoc4bZrMNl7MSoWgiA', auth=('[email protected]', 'ZoroYa11661246'))
6+
response = requests.get('https://mp.weixin.qq.com/s/pLmuGoc4bZrMNl7MSoWgiA')
87

98
#提取公众号伪代码
109

@@ -20,9 +19,14 @@
2019
smtp = 'smtp.126.com' #服务器地址
2120
#Todo:在下面实现自己的分词统计和发送邮件的操作
2221

22+
import mymodule.stats_word
2323
#统计内容的前100词频
24-
print(mymodule.stats_word.stats_text(text))
24+
statlist = mymodule.stats_word.stats_text_cn(content,100)
25+
statString = "".join(str(i) for i in statlist)
2526

2627

2728
# 发送邮件
28-
yag.send('[email protected]', '19100205 11661246', text)
29+
yag=yagmail.SMTP(sender,password,smtp)
30+
yag.send(recipients, '19100205 11661246', statString)
31+
32+
Binary file not shown.

0 commit comments

Comments
 (0)