Skip to content

Latest commit

 

History

History
50 lines (44 loc) · 2.33 KB

README.md

File metadata and controls

50 lines (44 loc) · 2.33 KB

Algorithms

Implementation of various Algorithms.Examples are mainly taken from Karunamachi.

Sorting Algorithms

  1. Bubble Sort
  2. Selection Sort
  3. Insertion Sort
  4. Merge Sort
  5. Randomized Quick Sort
  6. Heap Sort

Data Structure

1.Binary Heap

1. Build Min Heap
2. TopDown Heapify
3. BottomUp Heapify
4. Insert in Heap
5. DeleteMin
6. Increase Key
7. Decrease Key

2.Graphs

1. Adjacency List Representation
2. Breadth First Search(BFS)
3. Depth First Search(DFS)
4. Shortest Path using Dijkstra's Algorithm

Searching Algorithms

  1. Binary Search

Miscellaneous

  1. Divide Array: To get equal no of True and False
  2. Bitonic Array : To find the position where the array is strictly decreasing after strictly increasing from beginning
  3. K-Nearest Neighbours : To find k-nearest neighbours in an array
  4. Longest Common Substring : Finding Longest Common Substring using Rabin-Karp algorithm and Rolling-Hashing
  5. Maximum & Minimum No b/w 2 nodes in BST : Finding the maximum and minimum number between 2 nodes of BST if there exists a unique path using LCA(Least Common Ancestor)
  6. Costly Phone Number : https://www.hackerearth.com/practice/algorithms/graphs/shortest-path-algorithms/practice-problems/algorithm/costly-phone-number-december-easy-easy-medium/description/
  7. Coloring Trees : https://www.hackerearth.com/practice/algorithms/graphs/graph-representation/practice-problems/algorithm/coloring-the-tree-7e8a557a/
  8. Course Schedule II : https://leetcode.com/problems/course-schedule-ii/submissions/
  9. Number of Operations to Make Network Connected : https://leetcode.com/problems/number-of-operations-to-make-network-connected/
  10. Longest Happy String : https://leetcode.com/problems/longest-happy-string/
  11. Yet Another Array Problem! : https://www.hackerearth.com/practice/algorithms/greedy/basics-of-greedy-algorithms/practice-problems/algorithm/yet-another-array-problem-2/description/
  12. Possible Sums : https://www.hackerearth.com/practice/algorithms/dynamic-programming/2-dimensional/practice-problems/algorithm/possible-sums-5/description/