Stack A has the entries a, b, c (with a on top). Stack B is empty. An entry…

ISRO Scientist/Engineer SC 2008Modified — slightly modified from the official paper; see the solution

Stack A has the entries a, b, c (with a on top). Stack B is empty. An entry popped out of stack A can be printed immediately or pushed to stack B. An entry popped out of the stack B can only be printed. In this arrangement, which of the following permutations of a, b, c are not possible?

  1. A.

    b a c

  2. B.

    b c a

  3. C.

    c a b

  4. D.

    a b c

Attempted by 919 students.

Sign up free to check your answer

Sign up free

Explore the full course: Gate Guidance By Sanchit Sir

Loading lesson…