GateAI
CPU and I/O Scheduling

GATE CSE 2020 · Q35

MCQ2 marksMedium

Time

Consider the following five disk access requests of the form (request id, cylinder number) that are present in the disk scheduler queue at a given time. (P, 155), (Q, 85), (R, 110), (S, 30), (T, 115) Assume the head is positioned at cylinder 100. The scheduler follows Shortest Seek Time First scheduling to service the requests. Which one of the following statements is FALSE?

Select one answerSingle correct

Pick an option to check

Solution

Step-by-step verified solution

Official answer: B)

CPU and I/O Scheduling

Initial head position: 100 Pending requests: P (155), Q (85), R (110), S (30), T (115)

Using Shortest Seek Time First (SSTF) scheduling, the scheduler always services the request closest to the current head position:

  1. From 100:

    • Distance to P(155): $|100-155| = 55$

    • Distance to Q(85): $|100-85| = 15$

    • Distance to R(110): $|100-110| = 10$ (Minimum)

    • Distance to S(30): $|100-30| = 70$

    • Distance to T(115): $|100-115| = 15$

    • Service R (110).

  2. From 110:

    • Distance to T(115): $|110-115| = 5$ (Minimum)

    • Distance to Q(85): $|110-85| = 25$

    • Distance to P(155): $|110-155| = 45$

    • Distance to S(30): $|110-30| = 80$

    • Service T (115).

  3. From 115:

    • Distance to Q(85): $|115-85| = 30$ (Minimum)

    • Distance to P(155): $|115-155| = 40$

    • Distance to S(30): $|115-30| = 85$

    • Service Q (85).

  4. From 85:

    • Distance to S(30): $|85-30| = 55$ (Minimum)

    • Distance to P(155): $|85-155| = 70$

    • Service S (30).

  5. From 30:

    • Service P (155).

Sequence of servicing: R→T→Q→S→PR \rightarrow T \rightarrow Q \rightarrow S \rightarrow P.

  • Statement in (A): "T is serviced before P" is TRUE.

  • The statement in option (B) from the exam is "Q is serviced after S, but before T", which is FALSE because Q is serviced *before* S and *after* T.

Hence, option (B) is the false statement.

Try the question first, then check your work.

Think the official key or this write-up is wrong?

Report error or challenge

Examiner trap

The misconception this question tests

This CPU and I/O Scheduling previous year question is Q35 of the GATE CSE 2020 paper. Find more GATE CSE PYQs on CPU and I/O Scheduling in Operating Systems, or browse all GATE CSE PYQs.

Free diagnostic

Where do you stand for GATE?

Take the 20-minute diagnostic: the 3 topics that cost you the most marks, and a rank range. Or sit 5 related CPU and I/O Scheduling PYQs now with no account.

One GATE CSE PYQ every morning

An official question by email at 7 AM IST, with a link to its verified solution. Unsubscribe in one click.

CPU and I/O Scheduling in GATE CSE

CPU and I/O Scheduling has 25 GATE CSE PYQs across 22 papers from 2011 to 2026. 7 of them are 2-mark MCQs like this one, and GATE CSE 2020 has 2.

How GATE tests CPU and I/O Scheduling

More from GATE CSE 2020

Share this solution

A plain-text card for WhatsApp or Telegram study groups.

GateAI solution cardGATE CSE 2020 · Q35 · MCQ

Consider the following five disk access requests of the form (request id, cylinder number) that are present in the disk scheduler queue at a given time. (P, 155), (Q, 85), (R, 110), (S, 30), (T, 115) Assume the head is positioned at cylinder 100. The scheduler follows Shortest Seek Time First scheduling to service the requests. Which one of the following statements is FALSE?

Topic-wise GATE CS PYQs with verified steps

Independent practice explanation verified by the GateAI team. GATE is conducted by the IITs; question text follows the official paper.