Skip to content

Instantly share code, notes, and snippets.

View mayashavin's full-sized avatar
:octocat:

Maya Shavin mayashavin

:octocat:
View GitHub Profile
@mayashavin
mayashavin / Queue.js
Last active March 5, 2018 08:55
Data Structures - Queue Implementation in JS
function Queue(){
var storage = {},
head = 0,
tail= 0;
return {
enQueue: function(item){
storage[tail] = item;
tail++;
},