compilationcoding-style

good programming practice


I'm reading Randall Hyde's Write great code (volume 2) and I found this:

[...] it’s not good programming practice to create monolithic applications, where all the source code appears in one source file (or is processed by a single compilation) [...]

I was wondering, why is this so bad?


Solution

  • Because everything gets so crammed.

    If you have separate files for separate things then you'll be able to find and edit it much faster.

    Also, if there's an error, you can locate it more easily.