On 11 Jun 2013, at 01:08, Fábio Santos wrote:

> 
> On 10 Jun 2013 23:54, "Roel Schroeven" <r...@roelschroeven.net> wrote:
> >
> > You could do something like:
> >
> > new_songs, old_songs = [], []
> > [(new_songs if s.is_new() else old_songs).append(s) for s in songs]
> >
> > But I'm not sure that that's any better than the long version.
> 
> This is so beautiful!
> 
> 

I must disagree , this is unreadable and in my honor opinion not Pythonic at 
all.
I've learned it's always better to be explicit then implicit, and this snippet 
of code does a lot in an implicit way.

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

Reply via email to