by piinbinary · 7y ago · 0 comments
The trouble comes from functions where the various bits are all mixed together. This means that comments cannot easily name the sections (for me, one of the main advantages of a function is that it must be given a name), and you cannot easily narrow your reading to just the part you care about.
Another advantage of smaller functions is that some of them end up being general enough functionality to be worth sharing with other code.
Finally, it's possible to test doFirstBit() independently of the other logic in big().