Computer Science EngineeringVery hard

By the Sethi-Ullman labelling, the minimum number of registers needed to evaluate (a + b) * (c + d) without spilling is

  1. A. 1
  2. B. 2
  3. C. 3
  4. D. 4

Correct answer: B. 2

Each sum needs 1 register; with equal labels the product needs one more, so 2 registers.

More Theory of Computation, Compilers & Digital Logic (ISRO CS) questions

Exams that ask this topic