Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #ifndef __STACK_H_INCLUDED__
- #define __STACK_H_INCLUDED__
- #include "rover_util.h"
- struct StackNode {
- StackNode* next;
- RoverOperation* data;
- ~StackNode();
- };
- class stack
- {
- public:
- stack();
- ~stack();
- stack(const stack &other);
- stack& operator=(stack other);
- void push(RoverOperation* data);
- RoverOperation* pop();
- RoverOperation* peek() const;
- bool isEmpty() const;
- void print() const;
- private:
- StackNode* head;
- int count;
- void copyStack(const stack other);
- //to be plugged in
- };
- #endif
Add Comment
Please, Sign In to add comment