|
|
发表于 2015-12-7 09:48:48
|
显示全部楼层
参考:
- | partition(...)
- | S.partition(sep) -> (head, sep, tail)
- |
- | Search for the separator sep in S, and return the part before it,
- | the separator itself, and the part after it. If the separator is not
- | found, return S and two empty strings.
复制代码
---
- | split(...)
- | S.split(sep=None, maxsplit=-1) -> list of strings
- |
- | Return a list of the words in S, using sep as the
- | delimiter string. If maxsplit is given, at most maxsplit
- | splits are done. If sep is not specified or is None, any
- | whitespace string is a separator and empty strings are
- | removed from the result.
复制代码
---
http://bbs.fishc.com/forum.php?m ... peid%26typeid%3D403
|
|