CS FundamentalsVery hardGATE CS

The reference string at times 1–12 is 3, 5, 3, 8, 2, 5, 5, 9, 3, 9, 2, 2. With a working-set window Δ = 5 references, what are the working-set sizes at t = 5 and at t = 10?

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

Correct answer: D. 4 and 3

At t = 5 the window holds references 1–5: {3, 5, 8, 2}, size 4. At t = 10 it holds 6–10: 5, 5, 9, 3, 9, so {5, 9, 3}, size 3. The window counts references, not distinct pages, and repeats appear once in the set.

More Operating Systems questions

Exams that ask this topic