📅  最后修改于: 2022-03-11 14:45:38.232000             🧑  作者: Mango
1) how to find index of a word in a string:
my_string = "Hello World!"
my_string.index("l")
2) how to find the first occurance of a word in a string:
print(verse.index('and'))
3)how to find the last occurance of a word in a string:
print(verse.rindex('you'))