#include<stack.h>
#include<iostream.h>
#include"Stack.h"
const int maxstack=31;
enum Error_code{success,overflow,underflow};
typedef int Stack_entry;
class Stack{
bool empty() const;
Error_code copy_stack(Stack&dest,Stack&source);
private:
int count;
Stack_entry[maxstack];
};
bool Stack::copy_stack(Stack&dest,const Stack&source)
{
Error_code outcome=success;
if(0==count)
outcome=underflow;
else if(count>=maxstack)
outcome=overflow;
else
entry[count++]=dest;
return outcome;
}