Code Style - not really good list manipulation example - needs explanation #1086
Comments
|
Thanks for flagging this -- want to send in a pull-request to update that section? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In the Code Style chapter examples - Short Ways to Manipulate Lists there is an example "Add three to all list members."
"bad"
"good"
Unfortunately the "bad" and "good" examples do a different things:
Although the "good" code looks cleaner the result could be unwanted for example in case of huge lists or required side-effect of modifying the original list. The code at least needs an explanation.
The text was updated successfully, but these errors were encountered: