python check if string in string
if "blah" not in somestring:
continue
how to check if there is a word in a string in python
>>> str = "Messi is the best soccer player"
>>> "soccer" in str
True
>>> "football" in str
False
how to check if a string contains a word python
if word in mystring:
print('success')
how to check a string in if statement python
if var in ('stringone', 'stringtwo'):
dosomething()
how to check a string in if statement python
if var in ['string one', 'string two']:
do_something()