pycharm爬蟲運行後console中文出現xe4\xb8\亂碼的解決方法

對於Python3爬蟲抓取網頁中文出現輸出亂碼 import urllib.request  response = urllib.request.urlopen('http://www.12306.cn/mormhweb/')  html = response.read() print(html) 上面的代碼正常但是運行的時候結果遇到中文會以\xe7\x99\xbe\xe5\xba\xa6\xe4
相關文章
相關標籤/搜索