GeekInterview.com
   Home |  Tech FAQ  |   Interview Questions |  Placement Papers |  Tech Articles |  Learn |  Freelance Projects |  Online Testing |  Geeks Talk |  Job Postings |  Knowledge Base | Site Search |  Add/Ask Question

  GeekInterview.com  >  Placement Papers  >  Kshema Technology  >  Technical

 Print  |  
Question:  

What is a circular queue? Why is it better than a normal queue? Give some practical Examples of usage of circular queue.



April 04, 2008 16:10:56 #1
 payelmisty   Member Since: April 2008    Total Comments: 1 

RE: What is a circular queue? Why is it better than a normal queue? Give some practical Examples of usage of circular queue.
 
Circular queue is a bounded queue which implements arrays.

It is beter than a normal queue because in this we can effectively utilise the memory space.If we have a normal queue and have deleted some elements from there then empty space is created there and even if the queue has empty cells then also we cannot insert any new element because the insertion has to be done from one side only(i.e rear or tail) and deletion has to be done from another side(i.e front or head).But in case of circular queue the front and rear are adjacent to each other.
     

 

Back To Question