今天学习爬虫,成功了,开心的像个小孩
环境 python3.5 pycharm
import urllib.request url = "http://www.zhihu.com" response = urllib.request.urlopen(url) html = response.read() data = html.decode('utf-8', 'ignore') print(data)
今天学习爬虫,成功了,开心的像个小孩
环境 python3.5 pycharm
import urllib.request url = "http://www.zhihu.com" response = urllib.request.urlopen(url) html = response.read() data = html.decode('utf-8', 'ignore') print(data)