C++ linked list project manipulating stacks and queues