• A A queue follows the Last-In-First-Out (LIFO) principle, while a stack follows the First-In-First-Out (FIFO) principle.
  • B A queue allows elements to be inserted and removed from both ends, while a stack only allows elements to be inserted and removed from one end.
  • C A queue is typically implemented using a linked list, while a stack is typically implemented using an array.
  • D A queue is used for breadth-first search algorithms, while a stack is used for depth-first search algorithms.
  • Share this MCQ