Which of the below are not examples of Stack?
i. towers of hanoi
ii. Evaluation of fully parenthesized infix expression.
iii. pile of plates in a hotel.
ii & iii
All the below are examples of Stack (LIFO):
1.Towers of Hanoi - Because new tower is added on top, and also removed from top.
2.papers kept in a printer tray - top paper will be removed & added first
3.pile of plates in a hotel - top plate will be added or removed first.
Back To Top