Question
What is the worst-case time complexity of QuickSort with
a random pivot for sorting n distinct elements?Solution
Randomized quicksort has expected O(n log n) but rare worst-case O(n²) if partitions are very unbalanced (though random pivot makes worst-case improbable).
Select the odd one out
Select the numbers from among the given options that can replace the question marks (?) in the following series.
8, 9, 5, 16, 27, 25, 32, 81, 125...
Three statements are followed by four conclusions numbered I, II, III and IV. You have to consider these statements to be true, even if they seem at va...
Two statements are given, followed by two conclusions numbered I and II. Assuming the statement to be true, even if they seem to be at variance with co...
Find the analogous pair.
Annex : Lessening
In a certain code language, 'PAGES' is coded as 192', 'ABOVE' is coded as "180". What is the code for 'PRIOR' in that code language?Â
Select the word-pair that best represents a similar relationship to the one expressed in the pairs of words given below.
(The words must be consi...
CASE : DCVI :: PACK : ?
If '+' means '×', '×' means '–', '–' means '÷' and '÷' means '+', then what will come in place of the (?) in the following equation?
9 + ...
Six characters A, B, C, 1, 2 and 3 are written on different faces of a dice. Two positions of this dice are shown in the figure. Find the character on t...