| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
…strings Mention split direction in the docstring body, instead of in the 'maxsplit' param docstring.
Sorry, something went wrong.
There was a problem hiding this comment.
Looks good:
❯ ./python.exe
Python 3.13.0a2+ (heads/splitter!-dirty:c50dd463dd, Dec 21 2023, 14:51:45) [Clang 15.0.0 (clang-1500.1.0.2.5)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> help(str().split)
Help on built-in function split:
split(sep=None, maxsplit=-1) method of builtins.str instance
Return a list of the substrings in the string, using sep as the separator string.
sep
The separator used to split the string.
When set to None (the default value), will split on any whitespace
character (including \n \r \t \f and spaces) and will discard
empty strings from the result.
maxsplit
Maximum number of splits.
-1 (the default value) means no limit.
Splitting starts at the front of the string and works to the end.
Note, str.split() is mainly useful for data that has been intentionally
delimited. With natural text that includes punctuation, consider using
the regular expression module.
>>> help(str().rsplit)
Help on built-in function rsplit:
rsplit(sep=None, maxsplit=-1) method of builtins.str instance
Return a list of the substrings in the string, using sep as the separator string.
sep
The separator used to split the string.
When set to None (the default value), will split on any whitespace
character (including \n \r \t \f and spaces) and will discard
empty strings from the result.
maxsplit
Maximum number of splits.
-1 (the default value) means no limit.
Splitting starts at the end of the string and works to the front.
>>>Thanks everyone!
Sorry, something went wrong.
|
GH-113379 is a backport of this pull request to the 3.12 branch. |
Sorry, something went wrong.
…t() docstrings (pythonGH-113355) Clarify split direction in the docstring body, instead of in the 'maxsplit' param docstring. (cherry picked from commit 526d0a9) Co-authored-by: Erlend E. Aasland <erlend@python.org>
|
GH-113380 is a backport of this pull request to the 3.11 branch. |
Sorry, something went wrong.
…t() docstrings (pythonGH-113355) Clarify split direction in the docstring body, instead of in the 'maxsplit' param docstring. (cherry picked from commit 526d0a9) Co-authored-by: Erlend E. Aasland <erlend@python.org>
…strings (python#113355) Clarify split direction in the docstring body, instead of in the 'maxsplit' param docstring.
…strings (python#113355) Clarify split direction in the docstring body, instead of in the 'maxsplit' param docstring.
…strings (python#113355) Clarify split direction in the docstring body, instead of in the 'maxsplit' param docstring.
…strings (python#113355) Clarify split direction in the docstring body, instead of in the 'maxsplit' param docstring.
| Back | FazBrowse Home | New Git URL |
Mention split direction in the docstring body,
instead of in the 'maxsplit' param docstring.