摘要: import random,time sleeptime=random.randint(3, 5) time.sleep(sleeptime) 阅读全文
posted @ 2021-12-16 20:22 晨光曦微 阅读(484) 评论(0) 推荐(0) 编辑
摘要: """ utf8 编码""" from urllib.request import quote, unquote url1 = "https://www.baidu.com/s?wd=百度" # utf8编码,指定安全字符 ret1 = quote(url1, safe=";/?:@&=+$,", 阅读全文
posted @ 2021-12-16 20:15 晨光曦微 阅读(271) 评论(0) 推荐(0) 编辑
摘要: import os ... fname='xxx.csv' if not os.path.exists(fname): #文件存在则写表头 header默认=True df.to_csv(fname,mode='a',encoding='utf-8-sig',index=False,index_la 阅读全文
posted @ 2021-12-16 19:52 晨光曦微 阅读(1516) 评论(0) 推荐(0) 编辑
该文被密码保护。 阅读全文
posted @ 2021-12-16 10:55 晨光曦微 阅读(0) 评论(0) 推荐(0) 编辑