Draw Control Flow Graph of the given code 3.1 and code 3.2. respectively.
1.Draw Control Flow Graph of the given code 3.1 and code 3.2. respectively.
- Identify no. of predicate nodes and regions of the given code 3.1 and code 3.2. respectively.
- Determine Cyclomatic Complexity of the given code 3.1 and code 3.2. respectively.
code 3.1 |
code 3.2 |
1 If STDGrade >= 90Then 2 result= "A" ' display"A" 3 Else 4 If STDGrade >= 80Then 5 result= "B" ' display"B" 6 Else 7 If STDGrade>= 70Then 8 result= "C" ' display"C" 9 Else 10 If STDGrade>= 60Then 11 result= "D" ' display"D" 12 Else 13 result= "F" ' display"F" 14 End If 15 End If 16 End If 17 End If 18 PRINT “THIS IS YOURRESULT” |
If(1. num1 >100 and 2. num2 <200) 3. statement 1 else 4. while (num<100) 5. statement1 6. statement2 7. statement3 8. end while 9.endif |
Trending now
This is a popular solution!
Step by step
Solved in 2 steps with 3 images