3.8. Building Packages
Even when writing very small applications, it is recommended to block functions used for certain parts of the applications in separate files. When writing an application used for displaying stock charts, for instance, it can be useful to have separate libraries for functions related to retrieving data and functions for displaying the data. This will help you to reuse code for other applications. In addition, your functions are more consistent because not every application has its own implementation of a block of functions.
Writing reusable code is the first step to writing reliable code. The more often a piece of code is used, the more mature it will be because more testing has been done.
Another important issue is that ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access