permuting several lists (was Re: [Python-Dev] zip() and list-comprehension with commas)

Ka-Ping Yee ping@lfw.org
Wed, 12 Jul 2000 02:47:16 -0700 (PDT)


On Wed, 12 Jul 2000, Paul Prescod wrote:
> 
> But zip is not permute!
> 
> zip( [0,1,2,3,4],[0,10,20,30,40])=[0,11,22,33,44]

You mean 

zip([0,1,2,3,4], [0,10,20,30,40]) -> [(0,0), (1,10), (2,20), (3,30), (4,40)]

(It's late... maybe we all need some sleep.)  :)


-- ?!ng