[Tutor] On slicing

george fragos fragos.george at gmail.com
Thu Sep 17 11:21:24 CEST 2009


  If numbers=[1,2,3,4,5,6,7,8,9,10] and since "...any time the
leftmost index in a slice comes later in the seqence than the second
one... the result is always an empty sequence", why the slice
numbers[10:0:-2] produces the sequence [10,8,6,4,2] but not the
sequence []?


More information about the Tutor mailing list