I usually break list comprehensions before the 'for', and then again before the 'if' if they still need it. No backslashes. Implicit line continuation works as well within list comprehensions as it does in function calls.
"if [number for number in numbers if number < 10]:"
I would've used:
if any(number < 10 for number in numbers):
Or alternatively if any(itertools.imap(lambda x: x < 10, numbers)):
'any' short circuits its evaluation if it finds a true item , and the generator expression doesn't need to be evaluated fully. (I think the first is more readable.)I also didn't find all that much that was new and interesting in the article, but that's because I went hunting for articles like this when I first started getting into Python seriously, and have been programming full-time in it for 8 months now.