Finding the kth smallest element in the array
Given an array of numbers, how do we efficiently find the Kth smallest number in it? This problem is also called the selection problem. Widely used in order statistic (Find the smallest, biggest, median, top K elements etc…) For example in the array [6, 1, 9, 8, 3, 5, 4] the third smallest element is…