Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #2745
| From | Paul Rubin <no.email@nospam.invalid> |
|---|---|
| Newsgroups | comp.lang.python |
| Subject | Re: Is the function filter deprecated? |
| References | <mailman.88.1302132053.9059.python-list@python.org> <4d9d0dfe$0$29977$c3e8da3$5496439d@news.astraweb.com> |
| Date | 2011-04-06 22:23 -0700 |
| Message-ID | <7xd3kyprcd.fsf@ruckus.brouhaha.com> (permalink) |
| Organization | Nightsong/Fort GNOX |
Steven D'Aprano <steve+comp.lang.python@pearwood.info> writes: > filter(func, *seqs) -> [x for x in itertools.chain(*seqs) if func(x)] > although I suppose functional programming purists might object :) Maybe you really want filter(func, chain.from_iterable(seqs))
Back to comp.lang.python | Previous | Next — Previous in thread | Find similar
Is the function filter deprecated? Jabba Laci <jabba.laci@gmail.com> - 2011-04-06 19:20 -0400
Re: Is the function filter deprecated? Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2011-04-07 01:06 +0000
Re: Is the function filter deprecated? Paul Rubin <no.email@nospam.invalid> - 2011-04-06 22:23 -0700
csiph-web