0
0
Operating Systemsknowledge~10 mins

SCAN (elevator algorithm) in Operating Systems - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to describe the direction of the SCAN algorithm.

Operating Systems
The SCAN algorithm moves the disk arm in one [1] until it reaches the end of the disk.
Drag options to blanks, or click blank then click option'
Atrack
Bspeed
Cqueue
Ddirection
Attempts:
3 left
💡 Hint
Common Mistakes
Confusing 'direction' with 'speed' or 'track'.
Thinking the arm moves randomly instead of in a set direction.
2fill in blank
medium

Complete the code to explain what happens after the SCAN algorithm reaches the last request in one direction.

Operating Systems
After reaching the end of the disk in one direction, the disk arm [1] and starts servicing requests in the opposite direction.
Drag options to blanks, or click blank then click option'
Areverses
Bstops permanently
Caccelerates
Dignores
Attempts:
3 left
💡 Hint
Common Mistakes
Assuming the arm stops permanently after reaching the end.
Thinking the arm accelerates instead of reversing.
3fill in blank
hard

Fix the error in the description of the SCAN algorithm's movement.

Operating Systems
The SCAN algorithm moves the disk arm in one direction to service requests, reversing direction at the end of the disk. This is called [1].
Drag options to blanks, or click blank then click option'
ALOOK
BFCFS
CSCAN
DC-SCAN
Attempts:
3 left
💡 Hint
Common Mistakes
Confusing SCAN with FCFS which is first-come, first-served.
Mixing SCAN with LOOK or C-SCAN algorithms.
4fill in blank
hard

Fill both blanks to complete the SCAN algorithm's behavior description.

Operating Systems
The SCAN algorithm services requests by moving the disk arm towards the [1] end, then reverses direction at the [2] end.
Drag options to blanks, or click blank then click option'
Astart
Bmiddle
Cend
Drandom
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'middle' or 'random' instead of 'start' or 'end'.
Not understanding the arm reverses at the disk's physical ends.
5fill in blank
hard

Fill all three blanks to complete the dictionary comprehension describing SCAN's request servicing.

Operating Systems
serviced = {track: requests[track] for track in range([1], [2], [3]) if track in requests}
Drag options to blanks, or click blank then click option'
Astart_track
Bend_track
Cstep
Drandom_track
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'random_track' which is not valid for range.
Mixing up start and end positions or forgetting the step.