Consider the following table about processes, their burst time and arrival time. Which process shall finish second last as per the respective Gantt charts for non-preemptive SJF and Round Robin (time quantum = 10) scheduling methods?
| Process | Burst Time | Arrival Time |
|---|---|---|
| P1 | 9 | 0 |
| P2 | 30 | 0 |
| P3 | 4 | 0 |
| P4 | 8 | 2 |
| P5 | 11 | 6 |
Pick an option to check yourself, or open the answer below.
Show answer & explanation
Correct answer: D. SJF: P5; RR: P5
Explanation
SJF (non-preemptive): P3 0–4, P4 4–12, P1 12–21, P5 21–32, P2 32–62, so P5 finishes second last. RR (q = 10): P1 0–9, P2 9–19, P3 19–23, P4 23–31, P5 31–41, P2 41–51, P5 51–52, P2 52–62, so P5 again finishes second last.More System Software and Operating System questions
- Which of the following statements is correct for Pthreads?
- What shall be the 2nd request processed by the C-LOOK (Right) disk scheduling technique for the given request queue?
- What shall be the total head movement of cylinders for the C-SCAN disk scheduling technique if the head starts moving in the right directio…
- What shall be the 2nd request processed by the SCAN (Left) disk scheduling technique for the given request queue?
- What will be the total head movement of cylinders for the SSTF disk scheduling technique?
- What shall be the total head movement of cylinders if the FCFS disk scheduling method is used?