An open API service indexing awesome lists of open source software.

https://github.com/vishesh-gupta/algolvers

A :notebook: to my solutions to algorithms that I have encountered and want to face
https://github.com/vishesh-gupta/algolvers

algorthims cpp data-structures leetcode

Last synced: 3 months ago
JSON representation

A :notebook: to my solutions to algorithms that I have encountered and want to face

Awesome Lists containing this project

README

        

# Algolvers

Algolvers (acronym for Algorithm Solvers) is a set of solutions to multiple algorithm problems that were discovered online or asked to me while interviews

## Table of Contents

### **Data Structures**

- Lists
- Stack
- Queue
- Double Ended Queue
- Linked Lists
- Trees
- [Binary Search Tree](./data-structures/tree/bst/)
- [AVL Tree](./data-structures/tree/avl/)
- [Red-Black Tree](./data-structures/tree/red=black-tree/)
- Priority Queue
- [Heap](./data-structures/heap/)
- Fibonacci Heap
- Van Emde Boas Tree
- Graphs
- Adjacency List
- RangeQueries
- Quadtree
- kd-Tree
- RangeTree
- Hashing
- Cuckoo Hashing
-

### **Algorithms**

- **Array**
- Array Rotate
- Move Zeros
- Fisher–Yates Shuffle
- Kadane's Algorithm
- 3 Sum
- Rotate square matrix 90º
- Search Rotated Array
- Zero Matrix
- Two Sum
- Three Sum
- Maximum Difference First Before Second
- Pair Sum To Target
- Container With Most Water
- Trapping Rain Water
- Longest Consecutive Subsequence
- Stock Buy Sell k times
- MO’s Algorithm
- Maximum Occurance In Given Range
- Missing Number
- Generate Power Set of a set
- [LC-217.](https://leetcode.com/problems/contains-duplicate/) [Contains Duplicates](./array/containsduplicate.js)
- [LC-728.](https://leetcode.com/problems/self-dividing-numbers/) [Self Dividing Numbers](./array/selfdividingnumber.cpp)
- [LC-867.](https://leetcode.com/problems/transpose-matrix/) [Transpose Matrix](./matrices/transpose.cpp)
- [LC-896.](https://leetcode.com/problems/monotonic-array/) [Monotonic Array](./array/monotonic.cpp)
- [LC-961.](https://leetcode.com/problems/n-repeated-element-in-size-2n-array/) [N-Repeated Element in Size 2N Array](./array/n-repeatedelem.cpp)

- **Tree**
- [LC-94.](https://leetcode.com/problems/binary-tree-inorder-traversal/) [Binary Tree Inorder Traversal (Recursive)](./tree/binary%20tree/inordertraversal.js) Binary Tree Inorder Traversal (Iterative)
- LC-96. Unique Binary Search Tree
- LC-98. Validate Binay Search Tree
- [LC-101.](https://leetcode.com/problems/symmetric-tree/) [Symmetric Tree](./tree/binary%20tree/symmetric-tree.cpp)
- [LC-104.](https://leetcode.com/problems/maximum-depth-of-binary-tree/) [Maximum Depth of Binary Tree](./tree/binary%20tree/maxdepth-tree.js)
- [LC-144.](https://leetcode.com/problems/binary-tree-preorder-traversal/) [Binary Tree Preorder Traversal (Recursive)](./tree/binary%20tree/preordertraversal.js) Binary Tree PreOrder Traversal (Iterative)
- [LC-145.](https://leetcode.com/problems/binary-tree-postorder-traversal/) [Binary Tree Postorder Traversal (Recursive)](./tree/binary%20tree/postordertraversal.js) Binary Tree Post Order Traversal (Iterative)
- [LC-589.](https://leetcode.com/problems/n-ary-tree-preorder-traversal/) [N-ary Tree Preorder Traversal (Recursive)](./tree/n-ary%20tree/preordertraversal.js) N-ary Tree Preorder Traversal (Iterative)
- [LC-590.](https://leetcode.com/problems/n-ary-tree-postorder-traversal/) [N-ary Tree Postorder Traversal (Recursive)](./tree/n-ary%20tree/preordertraversal.js) N-ary Tree Postorder Traversal (Iterative)
- [LC-617.](https://leetcode.com/problems/merge-two-binary-trees/) [Merge Two Binary Trees](./tree/binary%20tree/symmetric-tree.cpp)
- [LC-700.](https://leetcode.com/problems/search-in-a-binary-search-tree/) [Search in a Binary Search Tree](./tree/binary%20tree/binary%20search%20tree/searchinvst.cpp)
- [LC-938.](https://leetcode.com/problems/range-sum-of-bst/) [Range Sum of BST](./tree/binary%20search%20tree/rangesumofbst.cpp)
- [LC-965.](https://leetcode.com/problems/univalued-binary-tree/) [Univalued Binary Tree](./tree/binary%20tree/univalued-tree.cpp)

- **String**
- Is Unique
- Check Permutation
- One Away
- String Compression
- String Rotation
- Naïve String Search
- Rabin–Karp
- Knuth–Morris–Pratt
- Boyer–Moore

- **Linked Lists**
- Reverse Iterative
- Reverse Recursive
- Floyd's Cycle Detection

- **Stack**
- [Balanced Parentheses](./stack/balanced_parenthesis.cpp)
- Infix to Postfix
- Prefix to Infix
- Prefix to Postfix
- Postfix to Prefix
- Postfix to Infix
- [Reverse a Stack](./stack/reverse.cpp)

- **Sorting**
- Insertion Sort
- Heap Sort
- [Merge Sort](./sorting/mergesort.cpp)
- Quick Sort
- Bubble Sort
- Counting Sort

- **Search**
- [Linear Search](./search/linearsearch.cpp)
- [Binary Search](./search/binarysearch.cpp)
- [Interpolation Search](./search/interpolationsearch.cpp)
- [Range Search 1-D](./search/rangesearch.cpp)

- **Selection**

- **Divide and Conquer**
- Recursive Max Sub Array

- **Dynamic Programming**
- [LC-53.](https://leetcode.com/problems/?search=53) [Maximum Sum of a Sub Array](./array/subrangemaxsum.cpp)
- Longest Common Subsequence
- Shortest Common Supersequence
- Longest Increasing Subsequence
- Probability Knight Remains In Chessboard
- Count All Matrix Paths
- Word Break
- Cutting a rod
- Integer Break (Maximum Product)
- Levenshtein distance
- Staircase Problem
- Matrix Chain Multiplication
- 0–1 Knapsack Problem
- Partition Problem
- Rod Cut
- Coin Change Problem

- **Greedy**
- Minimum product subset of an array
- Maximum product subset of an array
- Maximize the sum of arr[i]*i
- Minimum sum of product of two arrays
- Activity Selection Problem
- Egyptian Fraction
- Huffman Coding
- Huffman Decoding
- Water Connection Problem

- **Graph**
- Breadth First Search
- Number of islands
- Software Engineering

- **Design Patterns**
- Singleton
- Observer
- Mediator
- Prototype
- Command

- **Functional Programming**

- **Regular Expressions**

- **Mathematical Problems**
- [LC-509.](https://leetcode.com/problems/fibonacci-number/) [Fibonacci Number](./math/fibonaccinumber.cpp)

- **Shell**
- [LC-192.](https://leetcode.com/problems/word-frequency/) [Word Frequency](./shell/wordfrequency.sh)
- [LC-194.](https://leetcode.com/problems/transpose-file) [Transpose File](./shell/transpose-file)
- [LC-195.](https://leetcode.com/problems/tenth-line) [Tenth Line](./shell/tenthline.sh)
- [LC-193.](https://leetcode.com/problems/valid-phone-numbers/) [Valid Phone Numbers](./shell/validphonenumber.sh)

- **SQL**
- [LC-595.](https://leetcode.com/problems/big-countries) [Big Countries](./sql/bigcountries.sql)
- [LC-620](https://leetcode.com/problems/not-boring-movies/) [Not Boring Movies](./sql/notboringmovies.sql)
- [LC-627.](https://leetcode.com/problems/swap-salary/) [Swap Salary](./sql/swapsalary.sql)