ALLInterview.com :: Home Page KalAajKal.com
 Advertise your Business Here     
Browse  |   Placement Papers  |   Company  |   Code Snippets  |   Certifications  |   Visa Questions
Post Question  |   Post Answer  |   My Panel  |   Search  |   Articles  |   Topics  |   ERRORS new
   Refer this Site  Refer This Site to Your Friends  Site Map  Bookmark this Site  Set it as your HomePage  Contact Us     Login  |  Sign Up                      
tip   SiteMap shows list of All Categories in this site.
Google
 
Categories  >>  Software  >>  Testing  >>  Manual Testing
 
 


 

 
 Automation Testing interview questions  Automation Testing Interview Questions
 Manual Testing interview questions  Manual Testing Interview Questions
 QA Concepts interview questions  QA Concepts Interview Questions
 Mobile Testing interview questions  Mobile Testing Interview Questions
 Test Cases interview questions  Test Cases Interview Questions
 Test Documents Reporting interview questions  Test Documents Reporting Interview Questions
 Testing AllOther interview questions  Testing AllOther Interview Questions
Question
what is cyclomatic complexity? plz explain with example
 Question Submitted By :: Karthik
I also faced this Question!!     Rank Answer Posted By  
 
  Re: what is cyclomatic complexity? plz explain with example
Answer
# 1
Cyclomatic Complexity is a White Box Testing Type.
 
Is This Answer Correct ?    20 Yes 1 No
Srinivas
 
  Re: what is cyclomatic complexity? plz explain with example
Answer
# 2
Hai,
It's used to measure the complexcity of the software 
process.
It's used to measure the how many no.of test cases are used 
to test the app in all posible ways.
 
Is This Answer Correct ?    16 Yes 1 No
Sujatha
 
 
 
  Re: what is cyclomatic complexity? plz explain with example
Answer
# 3
Cyclomatic Complaxity comes under white box testing.
It means best path searching. To measure logical Complaxity 
of a prog.
for ex.

1-main()
2-if(a>1)
3{
------
------
}
4-else
5-{
-------
-------
}
}

Now a diagram would drawn from top as it would start from 1.
underneath it would be 2. and 2 would have two edges i.e. 3 
and 4. they would futher combine to form 5.

2,3,4 & 5 would make close regeoin while outside would 
become open region..

the arrows joining would be edges 2 would become predicate 
node. while others are simple nodes.

it has got a formula:

v(g)=Node-edges+2
v(g)= 5-5+2
v(g)=2
v(g)= predicate node+1
v(g)=1+1
v(g)=2

So its logical correct.

Please correct me if i'm wrong.
 
Is This Answer Correct ?    8 Yes 2 No
Amit
 
  Re: what is cyclomatic complexity? plz explain with example
Answer
# 4
Cyclomatic complexity is a metric used for complexity based 
testing proposed by McCabe
McCabe actually proposed 3 metrics:cyclomatic,essential and 
actual complexity.All 3 are based on the graphical 
representation of the program being tested.First 2 are 
calculated from the graph and the 3rd one is runtime metric.
mcCabe used the theory of graph in defining Cylocamatic 
complexityThere are sets of
linearly independent program paths through any program 
graph. A maximum set of these linearly
independent paths, called a basis set, can always be found. 
Intuitively, since the program graph
and any path through the graph can be constructed from the 
basis set, the size of this basis set should be related to 
program complexity. hence in a layman's language Cyclomatic 
complexity is number of Decision statements in the program 
being tested plus one.
 
Is This Answer Correct ?    1 Yes 1 No
Mrinalini
 
  Re: what is cyclomatic complexity? plz explain with example
Answer
# 5
In the Cyclometris Complexity we find the shortest path
between the nodes.The formula is 
  V(G)=e-n+2p   where,

G= Graph
e= no. of edges
n= nodes
p= no. of paths

plz Correct me if i m wrong....

nitin9360@yahoo.com
 
Is This Answer Correct ?    0 Yes 3 No
Nitin Verma
 
  Re: what is cyclomatic complexity? plz explain with example
Answer
# 6
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.
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. 
"M" is alternatively defined to be one larger than the 
number of decision points (if/case-statements, while-
statements, etc) in a module (function, procedure, chart 
node, etc.), or more generally a system.

Separate subroutines are treated as being independent, 
disconnected components of the program's control flow graph.


[edit] Alternative definition
v(G) = e − n + p 
G is a program's flowgraph 
e is the number of edges (arcs) in the flowgraph 
n is the number of nodes in the flowgraph 
p is the number of connected components 

[edit] Alternative way
There is another simple way to determine the cyclomatic 
number. This is done by counting the number of closed loops 
in the flow graph, and incrementing the number by one.

i.e.

M = Number of closed loops + 1 
where

M = Cyclomatic number.
 
Is This Answer Correct ?    1 Yes 1 No
Dheemanth Kumar
 
  Re: what is cyclomatic complexity? plz explain with example
Answer
# 7
The easiest way is to sum the number of binary decision 
statements (e.g. if, while, for, etc.) and add 1 to
it

Below is a simple program as an
example:
IF A = 354
THEN IF B > C
THEN A = B
ELSE A = C
ENDIF
ENDIF
Print A

one may calculate the cyclomatic complexity using the 
decision points rule. Since there are two decision points, 
the cyclomatic complexity is 2 + 1 = 3.
 
Is This Answer Correct ?    5 Yes 0 No
Dhakshna
 
  Re: what is cyclomatic complexity? plz explain with example
Answer
# 8
,.
 
Is This Answer Correct ?    0 Yes 0 No
Rf
 

 
 
 
Other Manual Testing Interview Questions
 
  Question Asked @ Answers
 
1. AMDOCS Testing2. DW testing3. ERP testing4. Mainframe testing5. SOX Testing6. Six sigma testing7. RUP-CMM testing  2
why we choosen testing but not developing  2
what is cyclomatic complexity? plz explain with example Accenture8
differentiate test case and test script  2
What features of sqlserver is generally used in database testing Mastek3
what is build and release and what is the difference b/w them?  2
What is meant by Testware?  1
what is difference between web application and client server application CTS2
when we will give testdata while writing testcases r during executing testcases for both positive and negative cases we give testdata PSI-Data-Systems3
What are the major testcase design techniques?  4
If you have executed 100 test cases ,every test case passed but apart from these testcase you found some defect for which testcase is not prepared,thwn how you can report the bug? Four-soft4
Can Anybody tell me What is diff. in Win2k namd Win-XP Thanks in advance Emptoris2
This is the question related to Traceability Matrix. Say we have 10 requirements for a project. If one of the testing team member misses the 9th requirement. Then how can we justify the Traceability Matrix and what is the further action to be taken. Please advice. ACS5
what is test director?  1
how to retrieve the test data? iSoft4
what all the metrics to be checked for a document ? Bally-Technologies1
what is the difference b/n DPD(Defect profile document) and DRD(Defect Report document). Zensar1
Diffrent between Smoke and Sanity tesing? AZTEC6
Is the Fundamental Test process and The test development process the same  1
How do u test any "web-site" as a secure site...? or How do you test the security of a web-site...? HCL7
 
For more Manual Testing Interview Questions Click Here 
 
 
 
 
 
   
Copyright Policy  |  Terms of Service  |  Help  |  Site Map 1  |  Articles  |  Site Map  |   Site Map  |  Contact Us interview questions urls   External Links 
   
Copyright © 2007  ALLInterview.com.  All Rights Reserved.

ALLInterview.com   ::  Forum9.com   ::  KalAajKal.com