python wrote:

[snip]

> 
> How could I keep the list1 not to change when remove list2's elements?
> 

You can't when the names list1 and list2 refer to the same list.  Try
making list2 a copy of list1,

list2 = list(list1)

Duncan
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to