#include "mydefs2b.h" #include // Linked list implementation of stacks. node :: node(int d, node* n) { data = d; next = n; } int Istack :: pop() { assert( !isempty() ); int temp = top -> data; // get data node* oldtop = top; // point to old top = top -> next; // unlink old delete oldtop; // discard return temp; }