Answers for "how to check if there is a word in a string in python"

49

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
Posted by: Guest on December-09-2019

Code answers related to "how to check if there is a word in a string in python"

Python Answers by Framework

Browse Popular Code Answers by Language