srinivasan srinivas wrote:

I want to do something like below:

1. first, second, third, *rest = foo

 2. for (a,b,c,*rest) in list_of_lists:

update to Python 3.0 (as others have pointed out), or just do

    first, second, third = foo[:3]
    rest = foo[3:]

    for item in list_of_lists:
        a, b, c = item[:3]
        rest = item[3:]
        ...

and move on to more interesting parts of your program.

</F>

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

Reply via email to