added working stack with tests