python装饰器

white 资源库 2018-07-16 82 次浏览
user_status = False def login(func): def inner(): _id = 'white' _pw = '123' global user_status if user_status == False: id = input('user:') pw = ...

简单的购物车系统

white 资源库 2018-06-16 88 次浏览
print("----------------商品列表-------------") products = [ ['iphone8',6888], ['Macbook',3888], ['小米',6888], ['联想',6888], ['Nike',6888], ['coffee',6888] ] for index,p in enumer...
回顶部