Wrote experimental code for the stack (untested yet)