Hacker News new | ask | show | jobs
by mcphage 1197 days ago
> The idea is that breaking a task up into digestible steps would both harbor more readable code, self-documentation and code reuse.

Sometimes. Other times it means you need to jump around in a file (or jump between files, even) to understand what's going on.

1 comments

Which is fine - any software of non-trivial complexity is going to require looking at the behaviour of multiple execution units, which may well be in different files. But if they're named sensibly and the dependencies are clearly maintained, the typical programmer is going to have a much easier time of "understand[ing] what's going on" than a single huge largely-unstructured blob of code. The moment you can't quickly see where a block starts and ends (without using IDE shortcuts) then the code has a readability issue.