Cyclomatic complexity is a software metric (measurement). It was developed by Thomas McCabe and is used to measure the complexity of a program. It directly measures the number of linearly independent paths through a program`s source code.
The concept, although not the method, is somewhat similar to that of general text complexity measured by the Flesch-Kincaid Readability Test.
Cyclomatic complexity is computed using a graph that describes the control flow of the program. The nodes of the graph correspond to the commands of a program. A directed edge connects two nodes if the second command might be executed immediately after the first command.
Definition
M = E − N + 2P
where
M = cyclomatic complexity
E = the number of edges of the graph
N = the number of nodes of the graph
P = the number of connected components.
Source:
http://www.onestoptesting.com/cyclomatic-complexity/definition.asp
The concept, although not the method, is somewhat similar to that of general text complexity measured by the Flesch-Kincaid Readability Test.
Cyclomatic complexity is computed using a graph that describes the control flow of the program. The nodes of the graph correspond to the commands of a program. A directed edge connects two nodes if the second command might be executed immediately after the first command.
Definition
M = E − N + 2P
where
M = cyclomatic complexity
E = the number of edges of the graph
N = the number of nodes of the graph
P = the number of connected components.
Source:
http://www.onestoptesting.com/cyclomatic-complexity/definition.asp
Search News
News Categories
What's the News?
Post a link to something interesting from another site, or submit your own original writing for the Testing community to read.
Most Popular News
-
How to Test Web Applications against SQL Injection Attacks
Published about 30-01-2009 | Rated +2 -
Top 20 practical software testing tips
Published about 02-02-2009 | Rated +2 -
India to lead in software testing
Published about 01-02-2009 | Rated +2 -
Software installation / uninstallation testing
Published about 16-02-2009 | Rated 0
Most Recent User Submitted News
- Frankenstein
Published about 07-07-2009 | Rated 0 - New API for Mycila Testing Framework...
Published about 13-05-2009 | Rated 0 - Java Test Tools
Published about 18-06-2009 | Rated 0 - Twenty essential firefox addons for testing
Published about 03-06-2009 | Rated 0







