CLASS
PRESENTATION
Presented By:
Swati Srivastava
PGT(Computer Science)
Kendriya Vidyalaya Barabanki
Lucknow Region
Data Structure
Data Structure
Data Structure
Stack Operation
Linear Structure
LIFO Technique
Stack Terms
Introduction
User-Defined
Built-in (Simple)
(Complex)
List Dictionary Tuple Set Linear Non –Linear
Linked
Stack Queue Tree Graph
List
Stack is a Linear data structure.
Linear Structure
LIFO Technique
Stack Operation
Stack Terms
Introduction
In stack addition of new data item and deletion
of already existing data item is done from only
one end, known as top.
Working of stack on the basis of Last-in-First-
out (LIFO) principal, it means last entered item
remove first.
Linear Structure
Stack Operation
LIFO Technique Stack of coins.
Introduction
Stack Terms
Stack of Plates.
Stack of Folded Clothes.
Stack of Boxes.
Undo/Redo Operations.
Function Call.
Back/Forward stacks on Browser.
Stack Operation
Stack Terms
LIFO Technique
Linear Structure
Introduction
Linear Structure
LIFO Technique
Stack Operation
Stack Terms
Introduction
Getting the most recent value
of stack i.e. value at top.
A situation when we are pushing
an element in stack that is full.
A situation when we are popping
an element from stack that is empty.
In case of insertion of any element in
Linear Structure
LIFO Technique
stack is called push.
Stack Operation
Stack Terms
Introduction
In case of deletion of any element from
stack is called pop.
In case of insertion and deletion of an element in a stack there are two
functions-
This function insert an element in stack.
Syntax: stackname.append()
This function delete an element from stack.
Syntax: stackname.pop(index)
Delete element at given index.
Syntax: stackname.pop()
Delete last element.
THANKS!