Given only a single array of size 10 and no other memory is available. Which of the following operation is not feasible to implement (Given only push and pop operation)?
A. Push
B. Pop
C. Enqueue
D. Returntop
Answer:C
Given only a single array of size 10 and no other memory is available. Which of the following operation is not feasible to implement (Given only push and pop operation)?
A. Push B. Pop C. Enqueue D. Returntop
Explanation: Another array of the same size is needed to perform Enqueue using only push and pop operations. However, since there is no additional memory available, the provided operation is not possible.