In this sub-project, you will implement one class:
A stack stores elements in an ordered list and allows insertions and deletions at one end in O(1) time.
The elements in this stack are stored in an array.
The run time of each member function is specified in parentheses at the end of the description.
A class which implements a stack using an array. The size of the array is fixed at initialization time. For run-time requirements, the number of elements in the queue is n. The array is considered to be full if all entries in the array are assigned.
The class at least three members:
StackAsArray( int n = 10 )
The constructor takes as an argument the size of the array and allocates memory for that array. The default number of entries is 10. Other class members are assigned as appropriate.
~StackAsArray()
The destructor deletes the memory allocated for the array.
This class has four accessors:
This class has three mutators:
The class has no friends.