mzimmers, the algorithm isn't really "sorting a stack", it's using three stacks to sort an arbitrarily-ordered input sequence. Step 2.1 and 2.2.* basically say "transfer all elements except the largest from stack 'in' to stack 'temp' (order doesn't matter here). The rest of step 2.* is "push the largest onto stack 'out'", and move everything from 'temp' back to 'in'". The last bit of that isn't a typical stack operation, but could just as easily be addressed by repeating step 2, only moving all but the largest element from 'temp' back to 'in' and pushing that next-largest value onto 'out'. If you want your head to start spinning, take a look at the PostScript programming language -- it's all about manipulating a stack, with almost no ability to define scopes! :(
fanfunstar, I suspect you're doing fine the way you are, and that the instruction to "use linked lists" means to implement your own stack. If you don't understand how to implement a stack using a linked-list, then just stick with what you're doing for now. But my questions from my original response still hold: What specific errors or incorrect output are you seeing? Can you figure out how to "clear" a stack by yourself? Also, I think your statements are reversed at lines 27-28 in the code you posted originally (though you may have changed it by now). With any luck, that will be enough to get you running.