An array of 25 distinct elements is to be sorted using quicksort. Assume that the pivot element is chosen uniformly at random. The probability that the pivot element gets placed in the worst possible location in the first round of partitioning (rounded off to 2 decimal places) is ________.
GATE CS 2019 (Forenoon) — Question 30
AlgorithmsSearching, Sorting, Hashing MechanismsNAT1 markMedium
A GATE question every morning
One real past-paper question every morning for your branch, answer hidden until you tap. Free on Telegram.
More on Searching, Sorting, Hashing Mechanisms
- GATE CS 2026 (Forenoon) · Q24Consider a hash table P[0, 1, , 10] that is initially empty. The hash table is maintained using open addressing with linear probing. The ha…
- GATE CS 2026 (Afternoon) · Q30The keys 5, 28, 19, 15, 26, 33, 12, 17, 10 are inserted into a hash table using the hash function h(k) = k 9 . The collisions are resolved…
- GATE CS 2026 (Afternoon) · Q38Consider an array A of integers of size n . The indices of A run from 1 to n . An algorithm is to be designed to check whether A satisfies…
- GATE CS 2025 (Forenoon) · Q33The pseudocode of a function fun( ) is given below: c fun(int A[0, ..., n - 1]) for i = 0 to n - 2 for j = 0 to n - i - 2 if (A[j] > A[j +…
- GATE CS 2025 (Forenoon) · Q65In a double hashing scheme, h 1(k) = k 11 and h 2(k) = 1 + (k 7) are the auxiliary hash functions. The size m of the hash table is 11. The…
- GATE CS 2025 (Afternoon) · Q20Consider an unordered list of N distinct integers. What is the minimum number of element comparisons required to find an integer in the lis…

