Again I should have said first, index 0, the first one. I can similarly go in and say I'd like all the things between index 2 and index 4. And again, remember what a b c that does. Index 2 says start a 0. 1, 2. So a, b, c.
我还是要说一遍,索引为0的元素,是第一个元素,我可以要求返回索引,2和4之前的所有元素,请记住2,是从0开始的,那么0,1,2对应的是。
And I can obviously do the other direction which is I can say skip to index 2 and all the remaining pieces. This lets me slice out, if you like, the front part or back part or a middle part of the tuple as I go along.
很明显我可以从索引2开始切片,所有剩下的元素,这可以让我2,如果你喜欢我这么说的话,取得元素的前面的或者后面的,或者中间的部分。
应用推荐