Give any two characteristics of stacks.

Answer

A stack is like a stack of books

The Characteristics of Stacks are:  

  • It is a data structure which follows LIFO (Last-in-First-Out)
  • The insertion and deletion happens at the same end i.e. from the top of the stack
  • Stack is implemented through Array or Linked list .
  • Stack is used in many algorithms like Tower of Hanoi, tree traversals.
  • If the allocated space for stack is full , and any attempt to add more elements will lead to stack Overflow . The opposite , any attempt to extract elements on an empty stack leads to Stack Underflow .

Slide1.JPG

Slide2.JPG
Slide3.JPG

Remove Ads
Teachoo · Class 12 Explore Class 12
Davneet Singh's photo - Co-founder, Teachoo

Made by

Davneet Singh

Davneet Singh is an IIT Kanpur graduate and has been teaching for 16+ years. At Teachoo, he breaks down Maths, Science and Computer Science into simple steps so students understand concepts deeply and score with confidence.

Many students prefer Teachoo Black for a smooth, ad-free learning experience.