CS FundamentalsHardTCS NQT · Infosys pattern

A disk has cylinders 0–199 and the head is at cylinder 76, moving towards cylinder 0. Pending requests: 45, 130, 12, 180, 90, 150, 60, 170. What is the total head movement under SCAN (elevator), which travels to the end of the disk before reversing?

  1. A. 232
  2. B. 260
  3. C. 276
  4. D. 256

Correct answer: D. 256

SCAN services every request in the direction of travel, continues to cylinder 0, then reverses: total movement 256 cylinders. LOOK would instead turn around right after the last request in that direction, giving only 232.

More Operating Systems questions

Exams that ask this topic