I'm trying to remove words from one list that appear in another. Then I have to copy the ones that are not repeated in a third list. When I make a comparison I have a problem with the list index
The language is python, last version.
listOne = ['Hello','Every','One','Here'] listTwo = ['Every','Here','Hi','Nice'] listThree =  for i in range(len(listOne)): for j in range(len(listTwo)): if listOne[i] == listTwo[j]: # <-- error here listOne.remove(listOne[i]) #Here is the problem if listOne[i] == listTwo[j]]: IndexError: list index out of range
I want to know why this happens.