例如:
squares = [0, 1, 4, 9, 16, 25, 36, 49, 64, 81] print(squares[:7]) print(squares[7:])
结果:
>>> [0, 1, 4, 9, 16, 25, 36] [49, 64, 81] >>>
0