Oops, try again.
Your remove_duplicates modifies the list that was passed to it. [4,
5, 5, 4] was modified to [5, 4]. Perhaps you should make a copy first!
So, as it's said in the brief, the new list with duplicate numbers was created, and then the old one was cleared from duplicate, but i still have error message like i have just modified the first list without creation of another one. Point me if i'm wrong somewhere.
def remove_duplicates(x): t =  for n in x: if n not in t: t_n = t.append(n) for n in x: if n in x: x.remove(n) return t_n