Implementing a Queue Data Structure in Javascript

preview_player
Показать описание
In this video, we are implementing the Queue Data Structure in Javascript. While a JavaScript Array can be used as a queue, this video is meant for educational purposes as we will go into more complex data structures in the future.

A queue is a simple linear data structure which is a container of objects that are inserted and removed according to the first in and first out principle. Elements can be enqueued from the back and dequeued only from the front.

Рекомендации по теме
Комментарии
Автор

Clear, easy to follow, thorough, and narratated in such a calm manner, my stress dropped 87% the moment I started watching. Bravo. Absolute gold.

sweetyeetus
Автор

Superb video...superb instructor...Kudos...keep it up bro...your way of teaching with easy and calm pace is the KEY !!

propertysmartcard
Автор

This is the best so far video about Queues on YT! Thank you, so much! Please carry on doing more videos. Do you have any related to algorithms, please?

dobrosawatoranska
Автор

Dude....how did you get so good!! I’m in a coding bootcamp about to graduate and I’m no where close to being this good, I’m struggling with DS and Algos and you code it up like it’s a piece of cake 🎂..

tonyvalentine
Автор

Thank you very much for the great explanation, I have a question:
at what point does this.first.next know all the path? for example: // front = 1 -> 2 -> null but we never modified this.first.next, only this.first when it was empty

erickgutierrez
Автор

so I understand that instead of using push pop methods you changed naming to queue/dequeue methods?

dobrosawatoranska
Автор

Is it really necessary to assign this.back = null when dequeueing the last element in the queue?

orangeiguanaduck
Автор

Why we have to point this.back = node? What is the significance of this line?

After This.back.next= node should handle it ?

priyanayak
Автор

I didn't get it how this.front get values after invite enqueue(x) function

yahyawiab
Автор

what is the different between use array inside queue and this way?

smithdragon