Algorithms

Algorithms for interviews

Sort (array data structure)

💡
All of these sorts are based on index key(number) to swap values

Base-case for these smart sort-algorithm ?

Devide and conquer technical

  • Binary search arr ( when left >= right => can’t find the value)

  • QuickSort ( when left >= right => can’t partition anymore)

  • MergeSort ( when arr.length === 0 => can’t devide the value anymore)

Binary search array

Mergesort

Quicksort

Recursive

Path-finding

Sliding window

Theory

Maximum sum of a contigious subarray of size 3

smallest sub-array with given sum

Backtracking

Combination Sum problem

Letter Combinations of a phone number

Dynamic programming

Best time to buy stock

String

Longest Palindromic Substring

To be updated ....