Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

what is cyclomatic complexity? plz explain with example

Answer Posted / deep singh kushwaha

Cyclomatic complexity is a software metric (measurement) 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.
One of the ways is 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.
Implications for Software Testing
M is a lower bound for the number of possible paths through the control flow graph.
M is an upper bound for the number of test cases that are necessary to achieve a complete branch coverage.
For example, consider a program that consists of two sequential if-then-else statements.
if (c1) {
f1();
} else {
f2();
}
if (c2) {
f3();
} else {
f4();
}
To achieve a complete branch coverage, two test cases are sufficient here.
For a complete path coverage, four test cases are necessary.
The cyclomatic number M is three, falling in the range between these two values, as it does for any program.

please suggest me if i m wrong..
e-mail-deepsingh.154@gmail.com

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

after completeing testing ,what would u deliver to the client?

2132


what is the critical defect in telecom domain?help me out from this prob its very urgent

3598


What is date driven testing?

1188


Hi, this is murthysharma. I need very urgently about some terms which are used in use cases? Plz give reply to me, if any body know, It is really very very urgent. 1. what is the difference between basic flow,exception flow and alternative flow? 2.what are non-functional requirements in use cases? 3.what are exceptions, special requirements, business rules, assumptions, constraints. Kindly give me with the example. Bcoz, I am very new to this use cases. thanks in Advance. Regards, M.MurthySharma

2022


what is the impact analysis?

2389


send the senario template

1957


What is bidirectional traceability ??? and how it is implemented

2141


What is ecp (equivalence class partition)?

1193


If date field is a text field write test cases to validate it?

2483


what are the risk factors in the project? what is the base for testplan and entry criteria ,exit criteria for test plan?

2458


Can you explain exploratory testing?

1116


What type of projects can include in Logistics Domain? and what is the type of domain for project which include Driving license renewal, Different type of title registration etc...

2988


What is the difference between web based application and client server application?

6725


Q) Create Preffered customer: As a customer when i purchase more than $5000 in goods since my first purchase, I become a preffered customer so that i can receive the benefits associated with that status.

2469


Architectural structure of the insurance project?

1313