Question discussion

Which data structure follows the Last-In-First-Out (LIFO) principle?

1545Medium DSSSB TGT Computer Science 0 replies 1 views
0

Which data structure follows the Last-In-First-Out (LIFO) principle?

  • AStack
  • BQueue
  • CHeap
  • DBinary tree
Correct answer: A

Explanation

In a stack the most recently inserted element is removed first.

Discussion 0

Nobody has replied yet. Start the discussion!