Identify the improper stack permutation for the input sequence a, b, c, d?
Hint:
A stack permutation is a permutation of items in the supplied input queue that is accomplished by transferring elements from the input queue to the output queue using a stack and the built-in push and pop operations.
1
c, d, b, a
2
d, c, a, b
3
b, d, c, a
4
a, d, c, b