摘要:
借鉴:https://www.cnblogs.com/shengyang17/p/8543712.html https://www.cnblogs.com/you-wei1/p/9693254.html 1.有两个列表 l1 = [11, 22, 33] l2 = [22, 33, 44] a.获取 阅读全文
摘要:
# 一、数字 # int(..) # 二、字符串 # replace find join strip startswith split upper lower format # tempalte = "i am {name}, age : {age}" # # v = tempalte.format(name='alex',age=19) # v = tempalte.for... 阅读全文
摘要:
# 字典 # dict # dic = { # "k1": 'v1', # "k2": 'v2' # } # 1 根据序列,创建字典,并指定统一的值 # v = dict.fromkeys(["k1",123,"999"],123) # print(v) # 2 根据Key获取值,key不存在时,可以指定默认值(None) # v = dic['k11111'] # pri... 阅读全文