0.0.49 • Published 8 years ago

data-structures-es6 v0.0.49

Weekly downloads
7
License
MIT
Repository
github
Last release
8 years ago

Data structures in Javascript

Build Status Code Climate Issue Count Coverage Status

Some data structures implemented in Javascript 2015 (es6): Stack, LinkedList

Install

npm install --save data-structures-es6

###Stack

####API

Methods

  • push
  • pop
  • peek
  • clear

####Example

var Stack = require("data-structures-es6").Stack

var stack = new Stack()

stack.push(1)

stack.push(2)

stack.pop()

stack.clear()

###LinkedList

####API

Getters

  • head
  • tail
  • length
  • current

Methods

  • resetCursor
  • next
  • push
  • at
  • removeAt

####Example

var LinkedList = require("data-structures-es6").LinkedList

var list = new LinkedList()

list.push(1)

list.push(2)

list.next()

var curentNode = list.current

console.log(curentNode.data) //2
0.0.49

8 years ago

0.0.39

8 years ago

0.0.36

8 years ago

0.0.34

8 years ago

0.0.33

8 years ago

0.0.31

8 years ago

0.0.26

8 years ago

0.0.1

8 years ago