I have a list of strings:
lst =['puppies com', 'company abc org', 'company a com', 'python limited']
If at the end of the string there is the word
limited, com or org I would like to remove it. How can I go about doing this?
I have tried;
for item in lst:
j= item.strip('limited')
j= item.strip('org')
I've also tried the replace function with no avail.
Thanks