Chapter 1. Bug Classification
This chapter covers the classification of bugs used in this book. It is based on a classification done by the computer scientist Donald Knuth. Each bug type is identified with the notation C.subcategory, where C is the initial of one of the main categories (A, D, F, or B) and subcategory is a descriptive name.
More details and explanations of these classifications can be found in Appendix A, “Classification of Bugs.” Types of bugs marked with an [*] do not appear in any of the examples.
A–Algorithm. The algorithm that the programmer designed is incorrect.
A.off-by-one. The program makes a calculation that is off by one.
A.logic. The algorithm has a logical flaw.
A.validation. Variables are not properly checked to ensure ...
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