For your eighth lab, you will implement singly-linked, linked-list
implementation of a stack and a queue, with an extra added reverse
method, that reverses the stack/queue.
Queue Methods:
- pubic void enqueue(Object elem)
- public Object dequeue()
- public boolean empty()
- public void reverse()
Stack Methods:
- pubic void push(Object elem)
- public Object pop()
- public boolean empty()
- public void reverse()
Each class should also contain a public static void main(String args[])
that thoughoughly tests all of your methods
Grading
- Commenting / following conventions / etc 10 points
- enqueue 10 points
- dequeue 10 points
- empty (queue) 5 point
- reverse (queue) 15 points
- push (stack) 10 points
- pop (stack) 10 points
- empty (queue) 5 points
- reverse (stack) 15 points
- main (for testing) 10 points
Submission
All file(s) required for
your project should be in the folder
https://www.cs.usfca.edu/svn/<username>/cs112/Lab8/