Questions about QUEUE...
Posted on 1998-12-09
Here questions about QUEUE, can give your suggest answer??:
Write the functions needed for the implementation of queues in a linear array when it can be assumed that the queue can be
emptied when necessary.
Write a function Append that will add an entry if there is room and, if not, will call another function ServeAll(Queue *Q) that
will empty queue. While writing this second function, you may assume the existence of an auxiliary function Service(QueueEntry
x) that will process a single entry that you have just removed from the queue.
By creating nodes and freeing nodes, write functions
that will process entries for linked queues and that can be substituted directly for their contiguous counterparts.
Write the following C functions for linked queues.
QueueFrontNode returns a pointer to the node at the front of the queue, whereas QueueFront returns a copy of the front
Any way Thank You for helping.