Skip to content

Instantly share code, notes, and snippets.

@jsprieto10
jsprieto10 / Queue.js
Created April 22, 2020 06:11
This is and implementations of a Queue in javascript using a double linked list
class Queue {
constructor(){
this.tail = null
this.head = null
this.length = 0;
}
shift(){
let temp = this.head
if (this.length < 2){