I want to make replace of all values that are in list(i) for a string (li) and return final string with replaced values.
Instead, my code replaces only one value at a time. Is there a way to fix this simple for loop?
li = str('Text 1. Text 2? Text 3!')
i = ['.', '?', '!']
for y in i:
t = li.replace(y,'')
print(t)