Assuming I have a string
string = 'i am a person i believe i can fly i believe i can touch the sky'
.
What I would like to do is to get all the words that are next to (from the right side) the word 'i'
, so in this case am, believe, can, believe, can
.
How could I do that in python
? I found this but it only gives the first word, so in this case, 'am'