Consider the following four processes with the arrival time and length of CPU burst given in milliseconds:
Process Arrival Time Burst Time P1 0 8 P2 1 4 P3 2 9 P4 3 5
Using the preemptive shortest job first (SJF / SRTF) scheduling algorithm, what is the average waiting time (in ms) for these processes?
| Process | Arrival Time | Burst Time |
|---|---|---|
| P1 | 0 | 8 |
| P2 | 1 | 4 |
| P3 | 2 | 9 |
| P4 | 3 | 5 |
Pick an option to check yourself, or open the answer below.
Show answer & explanation
Correct answer: A. (A) 6.5
More System Software and Operating System questions
- Which module gives control of the CPU to the process selected by the short-term scheduler?
- A fair share scheduler computes the priority of a process based on which of the following? (1) Processor utilization by the individual proc…
- Which of the following CPU scheduling algorithms may cause starvation of a process? (1) First-Come-First-Served (2) Round Robin (3) Priorit…
- A scheduling algorithm assigns a process's priority proportional to how long it has been waiting; every process starts at priority zero (th…
- Which of the following statements are CORRECT? (A) A process always checks the state of the currently executing process to enter its critic…
- At a particular time of computation, the value of a counting semaphore is 7. Then 20 P operations and 'x' V operations were performed on th…