CS FundamentalsHardGATE
Processes (arrival, burst) in ms: P1 (arrival 0, burst 7), P2 (arrival 2, burst 2), P3 (arrival 2, burst 4), P4 (arrival 5, burst 8). They are scheduled by non-preemptive Highest Response Ratio Next, where response ratio = (waiting time + burst) / burst, recomputed whenever the CPU becomes free. What is the average waiting time?
- A. 5.5 ms
- B. 5 ms
- C. 6 ms
- D. 4 ms
Correct answer: B. 5 ms
Recomputing the ratio each time the CPU frees up and always picking the highest gives completion times P1 7, P2 9, P3 13, P4 21, averaging 5 ms waiting. Plain non-preemptive SJF, which ignores the aging term, instead gives 5 ms.
More Operating Systems questions
- Processes (arrival, burst) in ms: P1 (arrival 0, burst 4), P2 (arrival 2, burst 6), P3 (arrival 4, burst 2), P4 (arrival 7, burst 8). They…
- Processes (arrival, burst) in ms: P1 (arrival 0, burst 4), P2 (arrival 2, burst 6), P3 (arrival 4, burst 2), P4 (arrival 7, burst 8)…
- Processes (arrival, burst, priority — a smaller number means higher priority): P1 (arrival 0, burst 4, priority 1), P2 (arrival 2, burst…
- Processes (arrival, burst) in ms: P1 (arrival 0, burst 4), P2 (arrival 2, burst 6), P3 (arrival 4, burst 2), P4 (arrival 7, burst 8). They…
- Processes (arrival, burst) in ms: P1 (arrival 0, burst 4), P2 (arrival 2, burst 6), P3 (arrival 4, burst 2), P4 (arrival 7, burst 8)…
- Processes (arrival, burst) in ms: P1 (arrival 0, burst 10), P2 (arrival 1, burst 3), P3 (arrival 2, burst 7), P4 (arrival 4, burst 2), P5…