background preloader

To study

Facebook Twitter

Khan Academy. List of algorithms. 5 important algorithms everyone should know « under a glass moon. 1. Merge Sort -O(nlogn) (where n is the input size) Of course we need to include a sorting algorithm in this list, but why Merge Sort? Why not any of the other comparison based sorting algorithms all of which run in O(nlogn)? The reason is that Merge Sort is probably the most simplest implementation of a “divide and conquer” algorithm out there.

The Merge Sort recurrence is also very common in other problems, so you can’t really avoid it. The simplicity is very attractive, it is in my opinion far easier to teach a novice Merge Sort rather than Quick Sort or any other contemporaries. 2. Dijkstra’s Algorithm is used to solve the “shortest path” path problem on a graph without negative weights. 3. Very simple with numberless applications. Connectedness testingshortest path(unweighted)bipartite testingtopological sortplanarity testingmaze solving 4. The FFT is an efficient algorithm for computing a discrete Fourier transformation and its inverse. 5. Like this: Like Loading... Project Euler.