CS FundamentalsVery hardGATE CS
Processes (arrival, burst): P1 (0, 3), P2 (2, 6), P3 (4, 4), P4 (6, 5), P5 (8, 2). Under non-preemptive Highest Response Ratio Next (response ratio = (waiting + burst) / burst), in what order do the processes run?
- A. P1 → P2 → P5 → P3 → P4
- B. P1 → P2 → P3 → P5 → P4
- C. P1 → P2 → P3 → P4 → P5
- D. P1 → P2 → P5 → P4 → P3
Correct answer: B. P1 → P2 → P3 → P5 → P4
Schedule: P1 0-3 | P2 3-9 | P3 9-13 | P5 13-15 | P4 15-20. At each decision point compute (W + S)/S for every waiting process; e.g. at time 9 P3 has (5+4)/4 = 2.25, P4 (3+5)/5 = 1.6, P5 (1+2)/2 = 1.5, so P3 runs. Pure SJF would instead give P1 → P2 → P5 → P3 → P4.
More Operating Systems questions
- Processes (arrival, burst, priority) with a smaller number meaning higher priority: P1 (0, 4, 3), P2 (1, 3, 2), P3 (2, 1, 4), P4 (3, 5…
- Processes (arrival, burst): P1 (0, 6), P2 (1, 4), P3 (2, 7), P4 (3, 2). Round Robin with quantum 2 ms (new arrivals join the queue before…
- Processes (arrival, burst) in ms: A (0, 4), B (1, 3), C (2, 2). Round Robin with quantum 2 ms; every switch from one process to a…
- Processes (arrival, burst): P1 (0, 8), P2 (1, 5), P3 (2, 2), P4 (4, 1), P5 (6, 4), scheduled by SRTF. How many times is a running process…
- Under FCFS, a long job L (burst 20) and three short jobs (burst 2 each) are scheduled. Case 1 arrivals: L at 0, S1 at 1, S2 at 1, S3 at 2…
- A 3-level feedback queue: Q0 is RR with quantum 4, Q1 is RR with quantum 8, Q2 is FCFS. New processes enter Q0; a process that uses its…