kopia lustrzana https://github.com/micropython/micropython
tests/basics/string_rsplit: Add tests for negative "maxsplit" argument.
rodzic
9f85c4fe48
commit
7400d88762
|
@ -52,3 +52,7 @@ print("/*10/*11/*12/*".rsplit("/*", 4))
|
|||
print("/*10/*11/*12/*".rsplit("/*", 5))
|
||||
|
||||
print(b"abcabc".rsplit(b"bc", 2))
|
||||
|
||||
# negative "maxsplit" should delegate to .split()
|
||||
print('abaca'.rsplit('a', -1))
|
||||
print('abaca'.rsplit('a', -2))
|
||||
|
|
Ładowanie…
Reference in New Issue