摘要: import re #首先 1开头,11位数就ok 简洁版本 # f1 = 13334564611 # s1 = re.findall('1\d{10}','13334564611') # print(s1) # 13 14 15 开头 f1 = '13334564611' s1 = re.find 阅读全文
posted @ 2018-08-18 16:57 星牧 阅读(355) 评论(0) 推荐(0) 编辑
摘要: python2与python3默认编码: python2:gbk print( u'上' ) 操作系统也是 gbk python3:unicode print( '上’ ) 字符编码转换关系: unicode --》encode (编码)--》gbk 其他形式的二进制 write gbk 其他形式的 阅读全文
posted @ 2018-08-18 15:59 星牧 阅读(205) 评论(0) 推荐(0) 编辑