So I'm doing an algorithm where you have to reverse each word in a string with Python. I've got a solution but why doesn't this piece of code change the list..
for i in l1:
i = i[::-1]
Here l1 contains all string elements. Why does this not change l1 in any way?