Comments by "MrAbrazildo" (@MrAbrazildo) on "5 Ways to Improve Your Code" video.
-
2:00, I disagree, because nowadays every command does many things. For instance, if you are searching something in an array, you can put a comment not the kind of "finding something", but for why are you searching that - not technically, but semantically. 2:30, here, I would write a comment about what is 'r', and why it's calculated like that. And I would do that at the right of the line, to avoid growing it downward. 3:45, I think it's not always possible: sometimes it's too intricate, and you will want to break it in parts, even harder to explain.
4:25, a majority of my f()s can be seen entirely in 1 screen. However (6:03), there are some of them that take 3 or more. And their content works as something private, that should not make sense to be exposed to the rest of the project, in a form of other f()s. Of course I'm not talking about reusable things (7:07), but about only 1 goal (7:55) that requires many steps, many initializations, many private and temporary data.
2
-
1