By process of deduction I have concluded that your lst looks something like this:
lst = [ ...[val1, val2], [val1, val2], [val1, val2]... ]
I think what happened here is you confused your 'for i in range', with a 'for i in' (I have done this many times also.)
The line where your error is occurring is:
lst.remove(lst[i])
You can correct this by simply changing your code like so:
for i in lst:
if i[0] ==1 or i[1] ==1:
lst.remove(lst[i])
return lst
The way your code was structured before list[i] didn't make any sense, your i was a number greater than the number of two-value-items in lst.
=D