摘要:''' Created on 2017年9月25日 @author: kearney ''' import random def get_UserAgents(): UserAgents= [ "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_3) AppleWebKit/537.36 (KHTML, like Gecko) C...
阅读全文
09 2017 档案
摘要:''' Created on 2017年9月25日 @author: kearney ''' import random def get_UserAgents(): UserAgents= [ "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_3) AppleWebKit/537.36 (KHTML, like Gecko) C...
阅读全文
摘要:''' Created on 2017年9月28日 @author: kearney ''' import os def isFile(filePath):#修改文件扩展名 filename=filePath.split('\\')[-1]#拆分文件路径获得文件名 fatherPath=filePath.replace(filename,'')#获得父级路径 s...
阅读全文
摘要:url=r'http://www.test.com/test.html' html=requests.get(url,headers=header) codetype=html.encoding#获取网页编码类型 html.encoding='GBK'#更改网页编码类型 print(html.text)
阅读全文
摘要:set1={1,2,3} set2=set([2,3,4]) print(set1,set2) #集合的运算 print(set1-set2)#集合的差 print(set1|set2)#集合的并 print(set1&set2)#集合的交 print(set1^set2)#集合的异或 print(set1<set2)#集合的包含 print('-'*70) #集合的方法 set1.ad...
阅读全文
摘要:教材上关于python3 isalnum的解释是:Python isalnum() 方法检测字符串是否由字母和数字组成。 但是实际应用中 #result:True 是不是可以理解isalnum为检测字符串是否包含符号。
阅读全文
摘要:三星GALAXY S4手机屏幕损坏,能正常开机,无法进行其他操作,拿去修屏幕已经没必要,现在主要把通讯录和照片导出到另一部安卓手机。 导出照片比较容易,手机连接到电脑找到相册文件夹(下图),即可。 下面着重说一下三星手机通讯录的导出。之前没有接触过三星的手机,仍然按照通讯录的一般导出方式开始。发现在
阅读全文
摘要:参考链接: https://stackoverflow.com/questions/28568070/filename-whl-is-not-supported-wheel-on-this-platform 之前一直在用python3.6版本,安装各种轮子非常顺利。 之后为了连接mysql 57数据
阅读全文
摘要:mysql5.7数据库位置 C:\ProgramData\MySQL\MySQL Server 5.7\Data 数据库中是否存在某一表格: 利用Navicat for MySQL迁移数据 选中数据库右键-数据传输-选择目标数据库——一键迁移 根据字段查询表: MYSQL里面需要根据某个字段名,查询
阅读全文
摘要:参考资料: https://www.testwo.com/blog/7269
阅读全文
|