Open In App

GATE | Gate IT 2005 | Question 65

To carry out white box testing of a program, its flow chart representation is obtained as shown in the figure below:

 



For basis path based testing of this program, its cyclomatic complexity is
(A) 5
(B) 4
(C) 3
(D) 2

Answer: (C)
Explanation:  

N(nodes) = 9



E(edges) = 10

Cyclomatic Complexity = E – N + 2P

= 10 -9 + 2*1

= 3
Quiz of this Question
Please comment below if you find anything wrong in the above post

Article Tags :