摘要: # FLAG = False # def login(func): # def inner(*args,**kwargs): # global FLAG # '''登入程序''' # if FLAG: # ret = func(*args, **kwargs) # func是被装饰的函数 # ret 阅读全文
posted @ 2019-01-07 20:43 招财牛猫 阅读(102) 评论(0) 推荐(0) 编辑
摘要: 1. 文件a.txt内容:每一行内容分别为商品名字,价钱,个数。 apple 10 3 tesla 100000 1 mac 3000 2 lenovo 30000 3 chicken 10 3 通过代码,将其构建成这种数据类型:[{'name':'apple','price':10,'amount 阅读全文
posted @ 2019-01-05 20:50 招财牛猫 阅读(168) 评论(0) 推荐(0) 编辑