Bad implementation of stack, list already does many things out of the box