Radix Sort – Searching and Sorting -The lower bound for Comparison based sorting algorithm (Merge Sort, Heap Sort, Quick-Sort .. etc is Ω(nLogn). i.e., they cannot do better than nLogn.
Algorithm
QuickSort – Searching and Sorting – Like Merge Sort, QuickSort is a Divide and Conquer algorithm. It picks an element as pivot and partitions.There are many different versions of quickSort that pick pivot in different ways.
Heap Sort – Searching and Sorting – Heap sort is a comparison based sorting technique based on Binary Heap data structure. It is similar to selection sort.where we first find the maximum element and place the maximum element at the end.
Minimum No of Platforms Required for a Railway/Bus Station – Greedy algorithm – Given arrival and departure times of all trains that reach a railway station , to find the minimum number of platforms required for the railway station so that no train waits.
K Centers Problem – Greedy Algorithm – Given n cities and distances between every pair of cities, select k cities to place warehouses ( ATM or Cloud Server)such that the maximum distance of a city to a warehouse is minimized.
Greedy Algorithm to find Minimum number of Coins – Greedy Algorithm – Given a value V, if we want to make change for V Rs. and we have infinite supply of each of the denominations in Indian currency.
Job Sequencing Problem – Greedy Algorithm – Given array of jobs where every job has deadline and associated profit if job is finished before the deadline.
Dijkstra’s Algorithm for Adjacency List Representation – Greedy Algorithm – We have discussed Dijkstra’s algorithm and its implementation for adjacency.In this post, O(ELogV) algorithm for adjacency list representation is discussed.
Dijkstra’s shortest path algorithm – Greedy algorithm – Dijkstra’s algorithm is very similar to Prim’s algorithm for minimum spanning tree. Like Prim’s MST, we generate a SPT (shortest path tree) with given source as root.
Prim’s MST for Adjacency List Representation – Greedy algorithm – We have discussed Prim’s algorithm and implementation for adjacency matrix representation. The time complexity for the matrix representation is O(V^2).