购物车 all_list = [ ('mac',9000), ('kindle',900), ('tesla',800), ('python',105), ('bile',2000), ] saving=input('输入资产:') #判断用户是否输入数字i shopping_car=[] # if saving.isdigit(): saving=int(saving) # for i in all_list: while True: for i,v in enumerate(all_list…