<strong> <br><a href="http://www.unlv.edu/">University of Nevada Las Vegas </a> <br><a href="http://www.egr.unlv.edu/"> Howard R. Hughes College of Engineering </a> <br><a href="http://www.cs.unlv.edu/"> School of Computer Science </a><br> <a href="http://www.cs.unlv.edu/~larmore"> My Home Page</a><br> </strong> UNLV CS Spring 2007 Assignment 4

CS 302 Assignment 4

Due date: Thursday, February 15, 2007, 8:30 AM in class.


All written assignments must be handwritten (not typed or printed from a computer file) in your own handwriting, on 8.5 by 11 inch paper, or on A4 paper. Write your name on each sheet, and do not fold the pages or crimp the corners. (You may use a paper clip or a staple.)
  1. Using pictures, show how to implement push and pop for each of the following implementations of the ADT Stack:
    1. Array implementation.
    2. Singly linked list implementation, with one pointer to the top.
  2. Using pictures, show how to implement enqueue and dequeue for each of the following linked list implementations of the ADT Queue:
    1. Simple (i.e., not circular) singly linked list, with front and rear pointers.
    2. Cicular singly linked list, with a single pointer to a dummy node.
  3. In every known application of the ADTs Stack and Queue, the items on the Stack or Queue represent ___________________ (two words).