Message192632
In http://docs.python.org/3.3/tutorial/introduction.html#strings:
In addition to indexing, slicing is also supported. While indexing is
used to obtain individual characters, slicing allows you to obtain
substring:
>>> word[0:2] # characters from position 0 (included) to 2 (excluded)
'Py'
>>> word[2:5] # characters from position 2 (included) to 4 (excluded)
'tho'
I think the second comment should be "from position 2 to 5", not "to 4".
I'm a Python newbie, sorry if it's not a bug. |
|
Date |
User |
Action |
Args |
2013-07-08 10:36:52 | xfq | set | recipients:
+ xfq, docs@python |
2013-07-08 10:36:52 | xfq | set | messageid: <1373279812.84.0.20851379601.issue18403@psf.upfronthosting.co.za> |
2013-07-08 10:36:52 | xfq | link | issue18403 messages |
2013-07-08 10:36:52 | xfq | create | |
|