Feedback for subjective question
Question 1: Consider the following sequence of push operations in a stack:
stack.push('1');
stack.push('2');
stack.push('3');
stack.push('4');
stack.push('5');
stack.push('6');
You can insert as many stack.pop()'s as you like in the above sequence of stack.push's to get a desired output. Which of the following cannot be an output?
stack.push('1');
stack.push('2');
stack.push('3');
stack.push('4');
stack.push('5');
stack.push('6');
You can insert as many stack.pop()'s as you like in the above sequence of stack.push's to get a desired output. Which of the following cannot be an output?
- 123456
- 325416
- 342561
- 342615
- E. 342165
Current Answer:
Be the first to post an answer to earn 100CR.