Department of Computer Science

PAD II

Spring Semester 1998

Dr. Maury Eggen

Homework Laboratory Assignment 6:

For this exercise we wish to revisit Stacks, Queues, Double Ended Queues
(Deques) and Priority Queues. 

For this exercise, write four menu driven programs which will use linked
data structures to model each of the above listed data structures. In 
the case of stacks the model must implement push, pop and empty. Use a 
single linked list for the stack application. For the queue model, implement
arrive, serve and empty. You may use either a single link or a double
link list for this application. For the deque, you must implement arrive
left, serve left, arrive right, serve right, and empty. Use a double
link list for this application. For the priority queue, use a single
link list and maintain the data in random order. This means that your
application must search for the priority to serve it. 

Include suitable display functions in each of the models.

Program due date: 

TR class: Thursday, 5  March 1998 9:55 am.

MWF class: Wednesday, 4 March 1998, 9:30am. 

Standard handin requirements.