Hacker News new | ask | show | jobs
by steveklabnik 1254 days ago
This is basically an eternal battle when teaching. Personally I prefer to try and stay to only idiomatic code if at all possible, but there's pros and cons to each approach.

(This is one reason why I'm glad other people are also writing books! Not everyone likes my style!)

1 comments

Or when necessary, use the verbose approach to lead toward and explain the idiomatic approach!
Even then: code examples get copied. People go "oh this works for me" and don't bother reading on to the better approach.

It's tough :)