News for hackers. Stuff that matters.
Re:Why Learning Haskell/Python Makes You a Worse Programmer by euccastro on Tuesday December 23, 2008 @08:19PM (#408335)

  # `None` means `lambda x: x` here
I find it more helpful to think of it as meaning `bool` in that context. I think the None special case is only there because filter() predates bool() in Python.
Re:Why Learning Haskell/Python Makes You a Worse Programmer by d0mine on Tuesday December 23, 2008 @08:37PM (#408365)
Thanks. `bool` is more readable.

  "\n".join(filter(bool, descriptions))
Or `len`

  "\n".join(filter(len, descriptions))