Which of the following is true about finding kth smallest element in an unsorted array? The best running time in finding
Posted: Fri Jul 01, 2022 5:47 am
Which of the following is true about finding kth smallest element in an unsorted array? The best running time in finding kth smallest is O(log(n)) as we can use the recursion The best running time in finding kth smallest is O(n) O First, we can sort it and then find the kth position. That will take O(nlog(n)) time in the best case O The best running time in finding kth smallest is O(1) as we find only the kth smallest