Commit eb83ffe1 authored by Benjamin Peterson's avatar Benjamin Peterson

fix error in split() examples (closes #22459)

Patch by Raúl Cumplido.
parent 61ff32f9
......@@ -1830,7 +1830,7 @@ expression support in the :mod:`re` module).
>>> '1,2,3'.split(',')
['1', '2', '3']
>>> '1,2,3'.split(',', maxsplit=1)
['1', '2 3']
['1', '2,3']
>>> '1,2,,3,'.split(',')
['1', '2', '', '3', '']
......@@ -2695,7 +2695,7 @@ produce new objects.
>>> b'1,2,3'.split(b',')
[b'1', b'2', b'3']
>>> b'1,2,3'.split(b',', maxsplit=1)
[b'1', b'2 3']
[b'1', b'2,3']
>>> b'1,2,,3,'.split(b',')
[b'1', b'2', b'', b'3', b'']
......
......@@ -296,6 +296,7 @@ Drew Csillag
Joaquin Cuenca Abela
John Cugini
Tom Culliton
Raúl Cumplido
Antonio Cuni
Brian Curtin
Lisandro Dalcin
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment