You are on page 1of 4

1.

 Determine the Cyclomatic complexity values for the CFGs in Assignment 1.

Predicates = 5
Cyclomatic complexity
=5+1
=6

 Generate the applicable basic paths for each CFG from assignment 1.

 [1-2-3-4-5-6-7-8-9]
 [1-2-3-4-5-6-7-8-10-11-13-14-15-3-16]
 [1-2-3-4-5-6-7-8-10-12-13-15-3-16]
 [1-2-3-4-5-16]
 [1-2-3-4-16]
 [1-2-3-16]

2.
1. Determine the Cyclomatic complexity values for the CFGs in Assignment 1.

Predicates = 10
Cyclomatic complexity
= 10 + 1
= 11

2. Generate the applicable basic paths for each CFG from assignment 1.

 [1-2-3-4-5-6-7-8-9-10-12-13-15-17-20-19-22]
 [1-2-3-4-5-6-7-8-9-10-12-14-15-17-20-19-22]
 [1-2-3-4-5-6-7-8-9-10-12-14-15-17-20-19-20-21]
 [1-2-3-4-5-6-7-8-9-11-8]
 [1-2-3-4-5-6-7-8-9-11-9]
 [1-2-3-4-5-6-7-8-9-10-12-8]
 [1-2-3-4-5-6-16]
 [1-2-3-4-5-16]
 [1-2-3-17-16]
 [1-2-3-17-20-19-20]
 [1-2-3-17-20-19-20-21]

You might also like