What is cyclomatic complexity and why is it important?



What is cyclomatic complexity and why is it important?..

Answer / sheetal

What is cyclomatic complexity
Cyclomatic complexity is a computer science metric
(measurement) developed by Thomas McCabe used to generally
measure the complexity of a program. It directly measures
the number of linearly independent paths through a programs
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. By definition,
CC = E - N + P
where
CC = cyclomatic complexity
E = the number of edges of the graph
N = the number of nodes of the graph
P = the number of connected components

Is This Answer Correct ?    2 Yes 1 No

Post New Answer

More ASP.NET Interview Questions

what is synchronization and asynchronization. what are the difference between two?

1 Answers   TCS,


What is state management technique?

1 Answers  


Explain how server control validation controls works?

2 Answers   CMS, Syntax Softtech,


What is the difference between a multi-layer and multi-tier applications?

1 Answers   Microsoft,


What happens if an ASP.NET server control with event-handling routines is missing from its definition?

1 Answers   MindCracker,


What is webresource axd?

1 Answers  


What are the merits and demerits of viewstate?

1 Answers   Siebel,


Which namespace do the classes, allowing you to support COM functionality, are located?

1 Answers  


What is boxing and unboxing ?

7 Answers   Accenture, Infosys, MedTek,


List down the sequence of methods called during the page load.

1 Answers  


How many types of triggers are there in update panel?

1 Answers  


what is webservices. howit is use in our project .

4 Answers   TCS,


Categories