stack implementation in JavaScript
HTML-код
- Опубликовано: 2 окт 2024
- stack data structure in JavaScript | what is stack | Stack Complexity | Stack Interview Questions
#algorithms #DataStructures #stacks
*Code
codepen.io/tec...
*My Courses
www.learn.heap...
www.learn.heap...
Follow me
/ techsith
/ algoanddsinjavascript
/ techsith
/ techsith1
/ 13677140
/ patelhemil
Help me translate this video.
www.youtube.co...
Note: use translate.goog... to translate this video to your language. Let me know once you do that so i can give you credit. Thank you in advance.
Best English pronunciation from India I ever listened! Well done you! 👌
I have one doubt...is push() pop() peek() all are inbuild methods of the stack or we are creating all those methods in this?
Broo I wish you still uploaded videos you have amazing content, such a clear explanation.
for the function empty(),
- would acceptable to implement as "_stack = null; " ?
- either way, why do you decrease "_top--" inside the while loop
when actually you can do outside the loop as ""_top = -1" ?
You just got a brand new subscriber..only function video on stack otherwise all of them are on using class.. got confused and thought only way is class for stacks implementation of array
Hello sir,
I am front end developer with 9year of experience, what do u suggest me to study to enhance my profile
Suneetha, it all depends on your professional goal. You can identify your weaknesses and focus on that area and master it. If you are looking for a new job, you may need to focus on algorithm and data structure as well. Anyway DS and algo will help you become a good programmer and further your goal
Clear and neat explanation
Huge fan of your video. Please do a tutorial on linked list. thx
Thanks! Will do!
What is different between stack and array ??
I don't get it. You can use array as stack, it has push and pop, so it would be better just extend Array class, from the other side if you build custom structure you shuld use linked list, using array is to easy way.
This is my linked list stack implementation:
jsbin.com/hoduradono/1/edit?js,console
Yes you can create it for using linked list as well. Or you can use objects. The arrays are closest to a stack so during an interview you want to take an approach that is the easiest so you can finish faster with better time complexity. Also I would have to show how to build linked list first. Maybe once I cover linkedlists I will make another video on this. Thanks for the example
Great work
Thank you! Cheers! thanks for watching!
Your Videos are Awesome :)
Hi sir....mailed u my question and also sent u request in linkdin...bdw great tutorial
I did send you a message just now. Keep up the good work.
@@Techsithtube sir you are the God of javascript and u r the ultimate saviour for js learners like us....i wish u a good health and please keeep doing by ur turorials ..ur doing amazing :)
Love u 😘😘😘😘😘😘😘
Appreciate all the love, Keep up the good work and thanks for watching!
@@Techsithtube 😍😍😍😍😍
Worthy 😉💯
Pawan, thanks for watching!