Reverse a Stack

What is the required output here ? I am printing the reversed stack but i am still failing all the test cases