Skip to content

Commit 034b625

Browse files
authored
Apply suggestion from @cclauss
1 parent dda416b commit 034b625

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

strings/split.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@ def split(string: str, separator: str = " ") -> list[str]:
1616
1717
>>> split(";abbb;;c;", separator=";")
1818
['', 'abbb', '', 'c', '']
19+
20+
>>> split("--a--b--c--", separator="--")
21+
['', 'a', 'b', 'c', '']
1922
"""
2023

2124
if len(separator) != 1:

0 commit comments

Comments
 (0)