Skip to content
Related Articles

Related Articles

Improve Article
Save Article
Like Article

Difference between C-LOOK and C-SCAN Disk Scheduling Algorithm

  • Last Updated : 21 Jul, 2020

C-LOOK Disk Scheduling Algorithm 

C-LOOK is the modified version of both LOOK and C-scan algorithms. In this algorithm, the head starts from the first request in one direction and moves towards the last request at another end, serving all request in between. After reaching the last request in one end, the head jumps in another direction and move towards the remaining requests and then satisfies them in the same direction as before. Unlike C-SCAN, the head pointer will move till the end request of the disk.

Example :

Attention reader! Don’t stop learning now. Get hold of all the important DSA concepts with the DSA Self Paced Course at a student-friendly price and become industry ready.  To complete your preparation from learning a language to DS Algo and many more,  please refer Complete Interview Preparation Course.

In case you wish to attend live classes with experts, please refer DSA Live Classes for Working Professionals and Competitive Programming Live for Students.

Consider a disk with 200 tracks (0-199) and the disk queue having I/O requests in the following order as follows: 



98, 183, 40, 122, 10, 124, 65

The current head position of the Read/Write head is 53 and will move in Right direction. Calculate the total number of track movements of Read/Write head using C-LOOK algorithm.

Total head movements
= (65 - 53) + (98 - 65)
  + (122 - 98)
  + (124 - 122) + (183 - 124)
  + (183 - 10) + (40 - 10)
= 333

C-SCAN Disk Scheduling Algorithm

C-scan algorithm, also known as Circular Elevator algorithm is the modified version of SCAN algorithm. In this algorithm, the head pointer starts from one end of the disk and moves towards the other end, serving all requests in between. After reaching the other end, the head reverses its direction and go to the starting point. It then satisfies the remaining requests, in the same direction as before. Unlike C-LOOK, the head pointer will move till the end of the disk, whether there is a request or not.   

Example –

Consider a disk with 200 tracks (0-199) and the disk queue having I/O requests in the following order as follows: 

98, 183, 40, 122, 10, 124, 65

The current head position of the Read/Write head is 53 and will move in Right direction. Calculate the total number of track movements of Read/Write head using C-scan algorithm.

Total head movements
= (65 - 53) + (98 - 65)
   + (122 - 98)
   + (124 - 122) + (183 - 124)
   + (199 - 183) + (199 - 0)
   + (10 - 0) + (40 - 10)
= 395

Difference between C-LOOK and C-SCAN Disk Scheduling Algorithm

 C-LOOKC-SCAN
1C-LOOK algorithm has the best performance in all disk scheduling algorithms.Whereas C-SCAN lags in performance, when compared to C-LOOK
2C-LOOK algorithm can handle requests more effectively than C-SCAN.Here handling of request is not so good as compared to C-LOOK algorithm.
3In above example of C-LOOK algorithm, the head moves from 53, serves all requests in right direction till it reaches the last request in one end. Then it jumps to the remaining requests and serve them in right direction only.In above example of C-SCAN algorithm, the head moves from 53, serves all requests in right direction till it reaches the other end. Then it jumps to opposite end and serve remaining requests in right direction only.
4C-LOOK provides low variance in response time and waiting time.C-SCAN provides uniform waiting time and response time.
5In C-LOOK algorithm, there is an overhead of finding the end requests.C-SCAN algorithm causes more seek time as compared to C-LOOK.
My Personal Notes arrow_drop_up
Recommended Articles
Page :

Start Your Coding Journey Now!