[EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > Is there a good way to splice two lists together without resorting to a > manual loop? Say I had 2 lists: > > l1 = [a,b,c] > l2 = [1,2,3] > > And I want a list: > > [a,1,b,2,c,3] as the result. > > I've been searching around but I can't seem to find a good example.
One way: result = 6*[None] result[0::2] = l1 result[1::2] = l2 Alex -- http://mail.python.org/mailman/listinfo/python-list