shanau2

导航

 

2018年11月26日

摘要: 1.字符编码 x='上' #unicode的二进制 》编码 》gbk格式的二进制 res=x.encode('gbk') #bytes 字节类型 print(res,type(res)) m=res.decode('gbk') print(m) #把gbk解码成unicode,python打印自动转 阅读全文
posted @ 2018-11-26 17:55 shanau2 阅读(105) 评论(0) 推荐(0) 编辑