PTY wrote:
> Which is better?
> 
> lst = [1,2,3,4,5]
> 
> while lst:
>   lst.pop()
> 
> OR
> 
> while len(lst) > 0:
>   lst.pop()
> 

allways that either-or stuff ! And why did you not consider

while len(lst) : list.pop()

a neat middle ground, wouldn't you say ?

Cheers, BB
--
666 ?? - 666 ~ .666 ~ 2/3 ~ 1-1/3 ~ tertium  non datur ~ the excluded middle
              ~ "either with us, or against us" !!
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to