摘要: 进程: 一些资源的集合。 一个进程里面最少有一个线程,主线程。线程: 程序执行的最小单位。 import threadingfrom threading import Threadimport time先执行主线程def run(): time.sleep(1) print('run...')sta 阅读全文
posted @ 2019-01-15 20:01 狐觞 阅读(187) 评论(0) 推荐(0) 编辑
摘要: import jsonpathres = jsonpath.jsonpath(d,'$..name') 字典,模糊匹配 阅读全文
posted @ 2019-01-15 19:58 狐觞 阅读(181) 评论(0) 推荐(0) 编辑
摘要: sys.argv,是获取到运行python文件的时候传入的参数 可以在pycharm中点击 阅读全文
posted @ 2019-01-15 19:42 狐觞 阅读(269) 评论(0) 推荐(0) 编辑
摘要: # try:# res = 1 / 0# except ZeroDivisionError as e:# print('出错啦,除数不能为0',e)# l = list()# l.append(1)# d = dict()# # d['name']='abc'# try:# print(d['nam 阅读全文
posted @ 2019-01-15 19:22 狐觞 阅读(174) 评论(0) 推荐(0) 编辑