CS FundamentalsModerateGATE CS

Two resource types X, Y. Available = (1,1). Allocation: P0 (1,0), P1 (0,1), P2 (1,1). Max: P0 (2,1), P1 (1,2), P2 (2,2). How many of the 3! = 6 orders of P0, P1, P2 are safe sequences?

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

Correct answer: B. 6

Need: P0 (1,1), P1 (1,1), P2 (1,1). Each fits the initial Available (1,1), and after any one finishes Available only grows, so every order works: 6 of 6.

More Operating Systems questions

Exams that ask this topic