CS FundamentalsVery hardGATE CS (PYQ pattern)

Holes in memory (in KB, in address order): 250, 240, 230, 180, 140. Processes arrive and stay resident in this order: 100, 190, 200, 150, 250 KB. A chosen hole is split and the remainder stays as a hole; there is no compaction. Which allocation policies place ALL five processes?

  1. A. Best-fit only
  2. B. First-fit only
  3. C. Worst-fit only
  4. D. First-fit and best-fit only

Correct answer: A. Best-fit only

Simulation with holes [250, 240, 230, 180, 140]: first-fit and worst-fit each leave a process unplaced, while best-fit keeps the right-sized hole for the large processes and places all five.

More Operating Systems questions

Exams that ask this topic