[Tutor] Explanation of Lists data Type
Kaushal Shriyan
kaushalshriyan at gmail.com
Wed Apr 12 11:12:15 CEST 2006
Hi All
I am referring to http://www.ibiblio.org/obp/thinkCSpy/chap08.htm
8.7 List slices
--------------------------------------------
>>> list = ['a', 'b', 'c', 'd', 'e', 'f']
>>> list[1:3]
['b', 'c'] -----> I understood this
>>> list[:4] --> Does this mean its list[0:4]
['a', 'b', 'c', 'd'] ----> I didnot understood this
>>> list[3:] --> Does this mean its list[3:0]
['d', 'e', 'f'] ----> I didnot understood this
>>> list[:] --> Does this mean its list[0:0]
['a', 'b', 'c', 'd', 'e', 'f'] ----> I didnot understood this
Please explain me
Thanks in Advance
Regards
Kaushal
More information about the Tutor
mailing list