问题:
I'm looking for a string.contains
or string.indexof
method in Python. 我正在寻找Python中的string.contains
或string.indexof
方法。
I want to do: 我想要做:
if not somestring.contains("blah"):
continue
解决方案:
参考一: https://stackoom.com/question/EQ8R/Python是否具有字符串-包含-子字符串方法参考二: https://oldbug.net/q/EQ8R/Does-Python-have-a-string-contains-substring-method
来源:oschina
链接:https://my.oschina.net/u/3797416/blog/3210204