mirror of https://github.com/python/cpython
SF patch #797180: Bug 792656: slicing explained
This commit is contained in:
parent
57d71289a1
commit
8170200ce2
|
@ -530,8 +530,9 @@ In Python 2.3 and beyond, \var{x} may be a string of any length.
|
||||||
\code{\var{x} = \var{i} + \var{n}*\var{k}} such that \code{0}
|
\code{\var{x} = \var{i} + \var{n}*\var{k}} such that \code{0}
|
||||||
\code{<=} \var{n} \code{<} \code{abs(i-j)}. If \var{i} or \var{j}
|
\code{<=} \var{n} \code{<} \code{abs(i-j)}. If \var{i} or \var{j}
|
||||||
is greater than \code{len(\var{s})}, use \code{len(\var{s})}. If
|
is greater than \code{len(\var{s})}, use \code{len(\var{s})}. If
|
||||||
\var{i} or \var{j} are ommitted then they become ``end'' values
|
\var{i} or \var{j} are omitted then they become ``end'' values
|
||||||
(which end depends on the sign of \var{k}).
|
(which end depends on the sign of \var{k}). Note, \var{k} cannot
|
||||||
|
be zero.
|
||||||
|
|
||||||
\end{description}
|
\end{description}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue