A comprehensive npm package of common data structures and algorithms in ES6. Developed with accessibility and minimal size in mind for use in production.
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
src
test
.eslintrc.json
.gitignore
.travis.yml
CONTRIBUTING.md
LICENSE
README.md
package.json
yarn.lock

README.md

program.js

NPM

Travis gary

A comprehensive and lightweight npm package of common data structures and algorithms to accelerate development.

About

Why is this module named program.js? An inspiration for this project was computer science pioneer Niklaus Wirth: author of the classic textbook Algorithms + Data Structures = Programs. We believe that the philosophy of algorithms and data structures being at the core of software is important, so this module is made in the textbook's honor.

Textbook

Current Implementations

Algorithms

  • Bubble Sort
  • Insertion Sort
  • Selection Sort
  • Quick Sort
  • Merge Sort
  • Factorial
  • Fibonacci
  • Combinations
  • Permutations

Data Structures

  • Node
  • DoubleNode
  • SinglyLinkedList
  • DoublyLinkedList
  • Stack
  • Queue
  • Heap
  • TreeNode
  • Binary Search Tree
  • HashTable

Usage

  1. Install the package using npm install --save programjs or yarn add programjs
  2. Import the feature set you would like to use (e.g. import { algorithms } from 'programjs')
  3. Access specific implementation through the feature set object (e.g. const sorted_array = algorithms.bubble_sort(array))

Contributing

If you're interested in contributing to program.js, refer to our guide.

License

We believe in open source projects. Our code is licensed under the MIT License..