This repository contains common algorithms, design patters, and techniques implemented in JavaScript. Code here is best used for learning purposes and practice. Contributing to this repo is appreciated and requested, especially if you're trying to learn JavaScript!
Note: Code from this repository should not be used in production! There are likely much more robust and well-tested built-in methods or npm packages to accomplish any task
This repository maintained by Nick Scialli and powered by awesome contributors like you!
-
Sorting
-
Searching
- Binary Search
- Exponential Search
- Fibonacci Search
- Interpolation Search
- Jump Search
- Linear Search
- TODO: Sublist Search (Search a linked list in another list)
- TODO: The Ubiquitous Binary Search
- Observer
- Revealing Module
- Singleton
- Builder
- Factory
- Adapter
- Bridge
- Decorator
- Flyweight
- Proxy
- Facade
- TODO: Mixin
- TODO: Prototype
- Strategy
- Linked List
- TODO: Doubly Linked List
- TODO: Stack
- Queue
- TODO: Binary Tree
- Graph
- Hash Table
- TODO: Heap
- TODO: Tree
- TODO: Graph
- TODO: Disjoint Set
- Binary Search Tree
Please make sure to claim an algorithm on the issues list (either by claiming an existing one or creating a new issue if the algo isn't listed). This helps make sure multiple people aren't doing the same work!
Contributing to this repository is appreciated and requested! Please look at the list above and select a section that has TODO next to it, or one that needs testing. In the former case, please add both the content of that section as well as matching tests in the tests
directory. Please Check the open issues before working on anything to make sure someone else isn't working on it already. If it looks available, open a new issue detailing what you plan to work on and I will verify no one else is working on it. Thank you!