Let's say I have an input string of 6 characters followed by a word "hello"
abcdefhello
or another set of data
quernwegngweghello
I mean, the word "hello" will definitely be at the end. How can I remove the word if possible?
The string is dynamic in number, meaning it will change accordingly so I will like to check whether the word contains "hello" in the last 5 characters and remove them if possible.