3 ms·
> Roughly half of that is entirely closing braces/parens... This is good, as it improves the code's readability. > ...but the other half is actual code reduct
by j-kidd 15y ago
> Roughly half of that is entirely closing braces/parens...
This is good, as it improves the code's readability.
> ...but the other half is actual code reduction/simplification, mostly from loop comprehensions.
This may not be good, as it can reduce the code's readability. List comprehension should only be used moderately, else you will end up with this:
http://blog.garlicsim.org/post/3504711416/nastiest-python-list-comprehension-ever http://blog.garlicsim.org/post/3504711416/nastiest-python-li...
Also, with python, at least you gain performance advantage by using list comprehension.