simple-dsa
v0.1.6
Published
A lightweight library that implements common **D**ata **S**tructures and **A**lgorithms (such as Linked Lists, Stacks, Queues, Binary Search, etc.) in JavaScript.
Readme
Simple DSA
A lightweight library that implements common Data Structures and Algorithms (such as Linked Lists, Stacks, Queues, Binary Search, etc.) in JavaScript.
Note: This library is intended for educational purposes only and should not be used in production code. There are more efficient and optimized implementations of these structures and algorithms in JavaScript (e.g., Map for HashMaps, Array for Stacks and Queues, etc.).
Currently implemented
Data Structures
- Linked List
- Stack
- Queue
- Hashmap
- Trie
Algorithms
- Binary Search
- Merge sort
- Quick sort
- BFS
- DFS
Problem solutions
- Arrays & Hashing
- groupAnagrams
- twoSum
- topKFrequent
- encodeDecodeString
- productExceptSelf
- longestConsecutiveSequence
- Linked Lists
- Reverse Linked List (iterative & recursive)
- Sliding-window
- maxSumOfSubArray
- Trees
- isBinaryTreeBalanced
- isSameBinaryTree
- isSubTree
- lowestCommonAncestor
- invertBinaryTree
- isValidBST
- Backtracking
- subsets
- Two Pointers
- isPalindrome
