April 2024
Beginner
656 pages
23h 19m
English
Keep it simple: as simple as possible, but no simpler.
– Albert Einstein
Writing a program involves gradually refining our ideas of what we want to do and how we want to express it. In Chapter 5, we produced the initial working version of a calculator program. Here, we’ll refine it. Completing the program – that is, making it fit for users and maintainers – involves improving the user interface, doing some serious work on error handling, adding a few useful features, and restructuring the code for ease of understanding and modification.
Symbolic constants. Use of functions. Code layout. Commenting ...