added code to implement a SetOfStacks