CS FundamentalsVery hardGATE CS · Software Engineering · Advanced

A program has 14 distinct operators, 22 distinct operands, 82 operator occurrences and 61 operand occurrences. Using Halstead's measures (volume V = N log2 n, difficulty D = (n1 / 2) x (N2 / n2), effort E = D x V), what is the effort E, to the nearest thousand?

  1. A. about 15,000
  2. B. about 14,000
  3. C. about 10,000
  4. D. about 29,000

Correct answer: B. about 14,000

n = 36, N = 143, V = 143 x log2 36 = 739.3, D = 7 x 61/22 = 19.41, so E = 14349, about 14000. Dropping the factor 1/2 doubles it, and natural logs change the volume.

More Software Engineering, Git and Cloud Basics questions

Exams that ask this topic