Data Structures :: Stacks - Discussion
Home > Data Structures > Stacks > MCQs Questions Discussion
76 / 93
Choose the correct option.
Let S be the original stack and S1 and S2 the two additional stacks then the following pseudo code is to reverse the stack S:
while (S not empty)
{
push(S1,pop(S));
}
while(S1 not empty)
{
push(S2,pop(S1));
}
while(S2 not empty)
{
push(S,pop(S2));
} ?
ATRUE
BFalse
CNot Answer
Answer: Option (Login/Signup)
Show Explanation
Asked In ::
STEP-BY-STEP
How can u say that the given code is true and vaild
Read Full Answer
Report Error
Please Login First Click Here