What is Cyclomatic Complexity?

后端 未结 15 1370

A term that I see every now and then is \"Cyclomatic Complexity\". Here on SO I saw some Questions about \"how to calculate the CC of Language X\" or \"How do I do Y with th

15条回答
  •  一个人的身影
    2020-12-07 20:36

    Cyclomatic complexity measures the number of times you must execute a block of code with varying parameters in order to execute every path through that block. A higher count is bad because it increases the chances for logical errors escaping your testing strategy.

提交回复
热议问题