GATE CS 2025 Set 2 | Question 26

Operating Systems › CPU Scheduling · MCQ · 1 mark · Answer: D

  1. Question 26Operating Systemsmcq1 mark
    Processes arrive at times 0, 1, 2, 8 ms with execution times 10, 13, 6, 9 ms respectively. Shortest Remaining Time First (SRTF) is used. Ignore context switching. Which ONE correctly gives the average turnaround time (ms)?
    • A.
      22
    • B.
      15
    • C.
      37
    • D.
      19
      ✓

    Answer: D

    Solution

    Answer: (D) 19 SRTF timeline:
    t=0  P1 starts
    t=2  P3 arrives (6) < P1 remaining (8) -> run P3 until t=8
    t=8  P3 done; P4 arrives(9). remaining P1=8,P2=13,P4=9 -> run P1 (8) until 16
    t=16 run P4 (9) until 25
    t=25 run P2 (13) until 38
    Completion: . Turnaround completion arrival: . Average ms.

More GATE PYQ on CPU Scheduling

All GATE CS Operating Systems PYQ →

Attempt GATE CS 2025 Set 2 in real GATE exam mode

Full paper with a timer, the GATE interface and a topic-wise analysis — free.

Create free account →