Q1. Which data structure is BEST for implementing a browser's 'back' button?
- A.Queue
- B.Stack✓ Correct
- C.Priority queue
- D.Hash table
Explanation
'Back' undoes the most recent action first — that is LIFO behaviour, which is exactly what a stack provides. A queue would give you the oldest page first, the reverse of what you want. Priority queues and hash tables don't encode action ordering.