摘要: ru=lambda x:x.decode('u8') rp=lambda x:x.replace('\\','/') gb=lambda x:x.decode('gbk') class ZIP: def __init__(s): import zipfile,ntpath,listdir,appuifw s.ZF,s.NP,s.LD,s.A=zipfile.ZipFile,n... 阅读全文
posted @ 2016-11-23 19:59 七月的尾巴_葵花 阅读(918) 评论(0) 推荐(0)
摘要: 在很多时候,你会想要让你的程序与用户(可能是你自己)交互。你会从用户那里得到输入,然后打印一些结果。我们可以分别使用raw_input和print语句来完成这些功能。对于输出,你也可以使用多种多样的str(字符串)类。例如,你能够使用rjust方法来得到一个按一定宽度右对齐的字符串。利用help(str)获得更多详情。 另一个常用的输入/输出类型是处理文件。创建、读和写文件的能力是许多程序所必... 阅读全文
posted @ 2016-11-23 00:22 七月的尾巴_葵花 阅读(414) 评论(0) 推荐(0)
摘要: import appuifw,e32,httplib Conn=httplib.HTTPConnection("10.0.0.172", 80) Conn.putrequest("GET",图片地址) Conn.putheader('Accept', '*/*') Conn.endheaders() gif = Conn.getresponse().read() gi=open("e:\\he... 阅读全文
posted @ 2016-11-23 00:12 七月的尾巴_葵花 阅读(347) 评论(0) 推荐(0)
摘要: 1 import appuifw as ui 2 import httplib 3 from os import abort 4 uia=ui.app 5 uin=ui.note 6 uiq=ui.query 7 e32=ui.e32 8 socket=httplib.socket 9 def cn(x):return x.decode('utf8') 10 uia.body=... 阅读全文
posted @ 2016-11-23 00:07 七月的尾巴_葵花 阅读(1021) 评论(0) 推荐(0)