Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit bf3165b

Browse files
committed
#14763: document default maxsplit value for str.split.
1 parent 7f0d888 commit bf3165b

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

Doc/library/stdtypes.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1304,8 +1304,8 @@ functions based on regular expressions.
13041304
Return a list of the words in the string, using *sep* as the delimiter
13051305
string. If *maxsplit* is given, at most *maxsplit* splits are done (thus,
13061306
the list will have at most ``maxsplit+1`` elements). If *maxsplit* is not
1307-
specified, then there is no limit on the number of splits (all possible
1308-
splits are made).
1307+
specified or ``-1``, then there is no limit on the number of splits
1308+
(all possible splits are made).
13091309

13101310
If *sep* is given, consecutive delimiters are not grouped together and are
13111311
deemed to delimit empty strings (for example, ``'1,,2'.split(',')`` returns

0 commit comments

Comments
 (0)