1 name = ["a","b",["alex","blue"],"c","d"] 2 print(name[0:-1:2]) 3 print(name[::2])#0和-1可以省略 4 print(name[:])#全部打印
列表切片的for循环
原文:https://www.cnblogs.com/archerzon/p/9482074.html