Added printFrontToBack method