find_certain_word_in_sentence.py


Sign up Free. Don't forget to check out our challenges, lessons, solve and learn series and more ...


Code Snippet

def main():

    string="I love python programming because python is fun, yes python is fun"
    print()
    number_of_pythons_in_string=string.count("python")
    print(number_of_pythons_in_string)
    
main()
                    

Try it yourself