str contains or python code example
Example 1: str.contains multiple strings
>>> searchfor = ['og', 'at']
>>> s[s.str.contains('|'.join(searchfor))]
0 cat
1 hat
2 dog
3 fog
dtype: object
Example 2: re contains
fullstring = "StackAbuse"
substring = "tack"
if substring in fullstring:
print "Found!"
else:
print "Not found!"