newbie - concatanating 2 lists
Remco Gerlich
scarblac at pino.selwerd.nl
Thu Feb 22 15:32:04 EST 2001
More information about the Python-list mailing list
Thu Feb 22 15:32:04 EST 2001
- Previous message (by thread): newbie - concatanating 2 lists
- Next message (by thread): newbie - concatanating 2 lists
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Steve Purcell <stephen_purcell at yahoo.com> wrote in comp.lang.python: > Hang on, it *is* still the shortest way in Python 2: > > li3 = [a+b for a,b in zip(li1,li2)] > li3 = map(lambda a,b:a+b,li1,li2) li3 = map(''.join,zip(li1,li2)) (as mentioned before) Is two strokes smaller. That's just my luck. First time I ever win at Perl Golf, it's in Python... -- Remco Gerlich
- Previous message (by thread): newbie - concatanating 2 lists
- Next message (by thread): newbie - concatanating 2 lists
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list