Python3.x 文件寫入出現錯誤 TypeError: write() argument must be str, not bytes

背景     用Pycharm編輯器Python3.x語言寫一個百度貼吧爬蟲程序 代碼如下: import urllib.request import urllib.parse def loadPage(url): headers = {"User-Agent":"Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML,
相關文章
相關標籤/搜索