STACK WITH ITS DIFFERENT
OPERATIONS
PRESENTED BY : -SUPRIYO DANA
CLASS ROLL NO : -L004 UNIVERSITY Ref No : -
COMPUTER SCIENCE AND ENGINEERING
FUTURE INSTITUTE OF TECHNOLOGY
2023
A stack is a linear data structure in which the insertion of a
newelement and removal of an existing element takes placeat
thesame endof the stack.
It's like a sequence of items that are accessible at only
oneendof the sequence.
What is Stack
Basic Operations on Stack
push()
pop()
top()
isEmpty()
size()
PUSH operation
It is used to insert an element into the stack.
If the stack is full, then it is said to be anOverflow
condition.
When we delete an element from the stack, the operation is known
as a pop.
If the stack is empty means that no element exists in thestack, this
state is known as an underflow state.
POP operation
Sizeoperation in Stack is used to return thecount of elements
that are present inside the stack.
SIZE Operation
isEmpty operation is used todetermine if the stack is empty or
not.
is Empty Operation