Operation on Stack - Push and Pop Algorithm [ Easiest Explain ]

preview_player
Показать описание
DATA STRUCTURES
Рекомендации по теме
Комментарии
Автор

Thanks sir apne bhut ache se smjha Diya ❤❤❤❤

mehakdeepkaur
Автор

राधे कृष्णा जी ❤ गौ माता जी सदा जय ❤❤❤❤❤

अभयदीप-जग
Автор

easiest is the best i am soo confuesd about algo until i saw this video my exam starts in 1hr and this is gen channel

spraygod
Автор

Absolutely awesome playlist but there missing some data structure i-e tree data structure which is also one of the most important concept in DSA.
It will be beneficial if you make a video on that so it will be helpful for upcoming generation to access a complete playlist from a mentor like you🤗⭐
Thanks😊

sayamuddin
Автор

sir tommorow is my exam but now my preparation is complete because of you

sam-vy
Автор

Thank you aap ne kaafi essay language may expalin kra 😊🙏💯

sakshimathur
Автор

Namaskar sir..,
I never thought this will help me the previous night before exam..i saw many tutorials but this helps me a lot truly..
Thank You
Love From Bangladesh 🇧🇩

nabbosarker
Автор

Here's a simple algorithm for inserting an element into a stack using if-else statements. This algorithm assumes that the stack has a maximum size and checks if there's space available before inserting the element.

1. Start
2. Define the stack (an array or list) and its maximum size (let's call it `maxSize`).
3. Initialize a variable `top` to -1 (this will track the index of the top element in the stack).
4. Function to insert an element (let's call it `push(element)`):
- If `top` is less than `maxSize - 1`, then:
- Increment `top` by 1.
- Insert `element` at `stack[top]`.
- Print "Element inserted."
- Else:
- Print "Stack Overflow! Cannot insert element."
5. End Function
6. End

This algorithm checks if there's space in the stack before inserting the new element. If the stack is full, it prevents the insertion and informs the user about the overflow condition.

AnjaliGarg-zo
Автор

I need your help about queues algorithm

zaibefi
Автор

Love from bangladesh, , , I did not understand the algorithm in class, I understood after watching your video

ara
Автор

Way of teaching is Great!! I could easily get a grip on the concepts!!

kinzaahmed
Автор

Sir for 6marks in exam this much is enough ha sir for both push and pop operation

Darshan.DP
Автор

You helped me alot
Thank you so much brother

zaibefi
Автор

thank you so much sir this video is really helpful.

Codelikepro
Автор

Very nice sir ... Sach m
Tq so much sir

jasmeetkour
Автор

sir mery liye ye topic buhot he difficult l ta but apka ye video dek kr entahy easy hugya

knowledgehub-xeey
Автор

Can I write step two in pop opretion like - set stack[top]=delete ?

mujthabamk
Автор

Sir, For POP operation :
Step 2: "Stack [Top]= Data/ Item" hoga otherwise it print "Stack underflow please response...?

mirajscreation
Автор

Sir various types operation ke question me je answer likh sakte hai

ThindThind
Автор

Sir thank you so much ...it was very helpful ..thank you

sampritiimajumder
visit shbcf.ru