Crimson Reason

A site devoted mostly to everything related to Information Technology under the sun - among other things.

Tuesday, March 18, 2008

Jack Ganssle On Cyclomatic Complexity

One of the tragedies of software engineering is that, in industry at least, we've successfully avoided the metrics-based quality revolution that transformed manufacturing. Few companies know their pretest bug rates in, say, defects per line of code. ...

Thirty-one years ago, Thomas McCabe proposed a metric called "cyclomatic complexity" to attach a quantitative measure to a function's complexity. It's one of many such measures but is by far the one most used. It measures the number of "edges" and "nodes" in a function, where a node is a computational statement and an edge represents the transfer of control between nodes. Cyclomatic complexity is then:
v(G)=edges–nodes+2


Check out the Web references in the article!

And the comments as well!

No comments:

Post a Comment

‹
›
Home
View web version

About Me

My photo
Babak Makkinejad
I had been a senior software developer working for HP and GM. I am interested in intelligent and scientific computing. I am passionate about computers as enablers for human imagination. The contents of this site are not in any way, shape, or form endorsed, approved, or otherwise authorized by HP, its subsidiaries, or its officers and shareholders.
View my complete profile
Powered by Blogger.