##### What is cyclomatic complexity of the above pseudo -code? 2

Consider the following pseudo- code

while (m<n) if (x>y ) and (a<b) then a=a+1 y=y-1 end if m=m+1 end while

What is cyclomatic complexity of the above pseudo -code?

- 2
- 3
- 4
- 5

Consider the following pseudo- code

while (m<n) if (x>y ) and (a<b) then a=a+1 y=y-1 end if m=m+1 end while

What is cyclomatic complexity of the above pseudo -code?

- 2
- 3
- 4
- 5

First of all , Software Engineering is out of syllabus for GATE.

Secondly, cyclometric complexity for pseudo -code is calculated as :

cyclometric complexity =1+no. of decision points in the code.

Here as we can see, there are 3 decision points (condition checking statements) in pseudo code , i.e.

So, cyclometric complexity =1+3=

4