Attachment 33258.....................
Printable View
Attachment 33258.....................
:devil: And that is one of the easier exercises we have to at class. As a matter of fact, we have programming today. :laugh:
Ok... :(
template<class Type>
void stackType<Type>::copyStack (stackType<Type>& otherStack)
{
delete[]list;
maxStackSize = otherStack.maxStackSize;
stackTop = otherStack.stackTop;
list = new Type [maxStackSize];
assert = (list!=NULL);
for (int j=0; j < stackTop; j++)
list[j] = otherStack.list[j];
}
This is nonsense... :blink:
Is that swearing in Mandarin? :laugh: