#ifndef _LIST_H #define _LIST_H #include #include #include #include class Elem { public: Elem(); ~Elem(); int make_tail(Elem& tail); private: Elem *next; Elem *prev; }; class Stack { public: Stack(int num); ~Stack(); int push(const int a); int pop(); int is_in(const int& elem); private: int size; int count; int *array; int head; //location in array of the first element of the stack int tail; //location in array of the last element of the stack }; #endif// _LIST_H