DSA/algorithms/CPlusPlus/README.md

4.5 KiB
Raw Blame History

C++

Arrays

  1. Counting Inversions
  2. Dutch Flag Algorithm
  3. Left Rotation
  4. Max Subarray Sum
  5. Shift Negatives
  6. BoyerMoore Voting Algorithm
  7. Reverse Array
  8. Sorted-Rotated Search Array
  9. Fractional Knapsack
  10. Quick Selection
  11. Remove Duplicates
  12. Leaders In The Array

Dynamic-Programming

  1. Longest Common Subsequence
  2. Longest Common Substring
  3. 0/1-knapsack
  4. Matrix chain Multiplication

Graphs

  1. Bellman Ford Algorithm
  2. kruskal Algorithm
  3. Breadth First Search
  4. Topological sort

Multiplication

  1. Karatsuba

Linked Lists

  1. All possible insertions
  2. Singly linked lists
  3. doubley linked lists
  4. Circular linked lists
  5. Removing Elements of given value
  6. Reversing a linked lists
  7. Merging two sorted linked lists
  8. Reorder List
  9. Detecting cycle in a singly linked list
  10. Find Merge Point of two singly linked list

Searching

  1. Linear Search
  2. Jump Search
  3. Binary Search
  4. Finding squareroot using Binary search
  5. KMP String Searching
  6. Ternary Search
  7. Interpolation Search
  8. Exponential Search

Stacks

  1. Balancing Parenthesis

  2. Reversing Stack

  3. Stack using Array

Sorting

  1. Bubble Sort
  2. Insertion Sort
  3. Quicksort
  4. Selection Sort
  5. 3 way Quick Sort
  6. Bucket Sort
  7. Comb Sort
  8. Counting Sort
  9. heap Sort
  10. Radix Sort
  11. Shell Sort
  12. Binary Insertion Sort
  13. Merge Sort
  14. Wave Sort
  15. Cycle Sort

Strings

  1. Rabin-Karp pattern search algo
  2. All subsequence of a string (Recursion)
  3. String reversal
  4. String tokanisation
  5. Anagram check

Trees

  1. Creating Binary Tree
  2. Counting and finding sum of all the nodes in BST
  3. Level Order Traversal
  4. Depth first Traversal
  5. Binary Search Tree
  6. In order morris traversal
  7. In order Predecessor and Successor
  8. Avl Tree
  9. Min Heap
  10. Finding the height of a given tree
  11. Finding the elements of a tree visible from top view

Maths

  1. Kaprekar Number
  2. Prime Number
  3. Prime Sieve
  4. Fibonacci Series

Recursion

  1. Tower of Hanoi
  2. Factorial
  3. Permutation