Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Assuming that the Shortest Remaining Time First ( SRTF - preemptive version of S

ID: 3794336 • Letter: A

Question

Assuming that the Shortest Remaining Time First (SRTF - preemptive version of Shortest Job First) scheduling policy is used to schedule job CPU bursts, choose the job that will be scheduled in each of the time slot starting at each of the times indicated in the table below. If no job is scheduled in a given time slot, choose "-". Convention: if two jobs have the same remaining time, choose job that arrived earlier first.

Job

Either A, B, C, D, or None

0

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

Job

Either A, B, C, D, or None

0

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

Job Arrival time CPU burst time /O wait time 4 2 4 4 3 0

Explanation / Answer

At time 0, only job D is in the ready queue, So, it gets CPU. When B arrives at the queue, both B and D have have same CPU burst time therefore D get the CPU again until C arrives. When C arrives, it has least CPU burst time than D and B. So, C gets the CPU. After C's execution, D and A have same CPU burst time but D gets the CPU again as D arrives first. After completion of D, A gets the CPU as burst time of A is less than that of B and so on. So, overall result will be:

Hope it helps, do give your response.

Time Job 0 D 1 D 2 D 3 C 4 D 5 D 6 A 7 A 8 B 9 B 10 B 11 B 12 A 13 A 14 A 15 A 16 B 17 B 18 B 19 -