CS FundamentalsHardGATE CS

Reference string (times 1 to 20): 2, 6, 1, 5, 7, 7, 7, 7, 5, 1, 6, 2, 3, 4, 1, 2, 3, 4, 4, 4. With window Δ = 5, what is the working-set size at time 10 and at time 14 (each window covers the last 5 references up to and including that time)?

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

Correct answer: C. 3 and 5

At t = 10 the window is references 6–10: [7, 7, 7, 5, 1], set [1, 5, 7]. At t = 14 it is references 10–14: [1, 6, 2, 3, 4], set [1, 2, 3, 4, 6].

More Operating Systems questions

Exams that ask this topic