I am new to programming and I wonder how to make a search in a text as follows.
I have a text with the following content
I won today as if he knew the truth Today I am lucid as if to die And had no more kinship with things
What I want and search this text has the word
truth if you
I wanted to store a string starting word of "truth" until the words had meaning the string would be
Today I am really lucid as if you were to die and had no
and omit the rest of the text.
Already I tried to search the position of the word "truth" but not worked.