Cognitive Complexity

This technical guide introduces Cognitive Complexity, a new metric formulated to more accurately measure the relative understandability of coding methods. In doing so, it addresses and makes up for the shortcomings of Cyclomatic Complexity.

Unlike Cyclomatic Complexity, Cognitive Complexity uses human judgement to assess how structures should be counted and decide what should be added to the model as a whole. As a result, it yields method complexity scores, which overwhelmingly strike programmers as fairer relative assessments of maintainability than have been available with previous models.



We use cookies to optimize your experience, enhance site navigation, analyze site usage, assist in our marketing efforts. Privacy Policy