Description
Problem Definition
Write a program that implements the following disk-scheduling algorithms:
1. FCFS
2. SSTF
3. SCAN
4. C-SCAN
5. LOOK
6. C-LOOK
Your program will service a disk with 5,000 cylinders numbered 0 to 4,999. The program will
generate a random series of 1,000-cylinder requests and service them according to each of the
algorithms listed above.
The program will take two arguments, initial position of the disk head
(default value 2000) and the algorithm to be used.
The program will output the sequence in
which the requests were served and after the sequence it will print the average & total amount
of head movement for the requests. Make report comparing the average & total amount of
head movement required by each algorithm.
Reference: Section 10.4 Disk Scheduling, Avi Silberschatz and Peter Baer Galvin and Greg Gagne.
Operating System Concepts (10th Edition). Wiley, 2018.