1 列表和元组 1.列表基本操作 1. 列表赋值 a = [1,2,3,4,5,6,7,8] a[0] = 100 #the result : [100, 2, 3, 4, 5, 6, 7, 8] 2. 元素删除 a = [1,2,3,4,5,6,7,8] del a[0] #the result : [2, 3, 4, 5, 6, 7, 8] 3. 分片赋值 a = [1,2,3,4,5,6,7,8] a[::2] # [1, 3, 5, 7] a[-2:] # [7, 8] a[1:1] =…