27 Qs · since 2012 · 39 marks · 1.6 marks/paperMedium yield
Across GATE CS exams, Searching, Sorting, and Hashing are tested with a strong emphasis on exact comparison/swap counts, worst/best-case edge cases (especially for Quicksort and si… Guide
Topic guide
Across GATE CS exams, Searching, Sorting, and Hashing are tested with a strong emphasis on exact comparison/swap counts, worst/best-case edge cases (especially for Quicksort and simultaneous min-max finding), trace-based simulation (such as step-by-step hashing probes and merge passes), and asymptotic tradeoffs for specialized or composite data inputs. Questions range from conceptual 1-mark classification to rigorous 2-mark NATs requiring precise manual execution of collision resolution or optimal merge trees.
Simultaneous Min-Max Comparison Counting
common · mixed · 2 marks · 2021, 2014
Determining the exact minimum comparisons or bounding intervals required to find both the minimum and maximum elements in an array of size using pairwise grouping.
Hash Table Collision Resolution Trace & Metric Computation
common · mixed · 1.5 marks · 2026, 2025, 2021, 2015
Tracing the insertion of given integer keys into a hash table using chaining, dynamic bitwise trees, or open addressing (linear, quadratic, or double hashing) to find slot positions, chain lengths, or load factor .
Quicksort Pivot Selection & Partition Behavior
common · mixed · 1 marks · 2019, 2016, 2014
Analyzing comparisons, worst-case recurrences, or probability of bad partitions under various pivot selection rules (first element, central element, or uniformly random pivot) on specific input permutations.
Merge Sort Traces and Multi-way/Optimal Merging
common · NAT · 1.5 marks · 2026, 2014
Calculating exact comparison counts using Huffman-like greedy 2-way merging (Optimal Merge Pattern) or step-by-step tracing of recursion trees and specific merge predicates (e.g., void merges).
Search/Sort Variations on Non-standard Inputs
occasional · MCQ · 2 marks · 2025, 2013, 2012
Evaluating asymptotic bounds for searching in specialized structured arrays (e.g., bitonic arrays), sorting compound items (e.g., strings of length ), or inverse-solving element counts for fixed asymptotic time targets.
Operation-Frequency-Driven Data Structure Selection
rare · MCQ · 2 marks · 2015
Choosing the data structure (unsorted array, min-heap, balanced BST) that minimizes total asymptotic time given a specific non-uniform frequency mix of operations.
Open Addressing Probe Address Calculation
common · NAT · 1 marks · 2020
Given hash functions (e.g., and ) and a table size , calculate the exact slot index inspected at a specific probe number for a given key in open addressing schemes like double hashing or linear probing.
Hash Table Insertion Tracing & Occupancy
common · MSQ · 1 marks · 2026
Given an initial empty table and a sequence of keys with a specified collision resolution method (e.g., linear probing with wrap-around modulo arithmetic), trace step-by-step insertions to identify occupied or unoccupied slot indices.
Probability and Expectation under SUHA
common · MCQ · 1.5 marks · 2022, 2014
Evaluate the probability of specific slot configurations (e.g., specific slots remaining empty after multiple insertions) or calculate expected slot chain lengths / expected keys per slot using linearity of expectation under simple uniform hashing assumptions.
Theoretical Concepts & Adversarial Collision Resistance
occasional · MCQ · 1 marks · 2023
Test understanding of hash function properties, limitations of deterministic hashing (division/multiplication methods) against worst-case adversaries, and the role of universal hashing in achieving expected performance.
Standard Algorithm Worst-Case Comparison
common · MCQ · 1 marks · 2016
Matching or listing the tight asymptotic worst-case time complexities of classical sorting algorithms like Insertion sort, Merge sort, and Quick sort.
Binary Search Decision Tree and Worst-Case Probe Count
occasional · NAT · 2 marks · 2017
Determining the exact minimum number of worst-case probes required by an optimal algorithm to locate a boundary or transition point in a sorted/monotone array of fixed size .
Recurrence and Operation Count for Recursive Searching
common · MCQ · 1 marks · 2021
Identifying the asymptotic bound on the number of arithmetic/comparison operations executed during recursive binary search.
Simultaneous Min and Max Comparisons (Even $n$)
Used when finding both minimum and maximum of an even number of elements with minimum comparisons by pairwise grouping.
Simultaneous Min and Max Comparisons (Odd $n$)
Used when calculating optimal min-max comparisons for an odd number of elements.
Worst-case 2-Way Merge Comparisons
Used during each step of the optimal merge pattern when combining two sorted arrays of sizes and .
Load Factor of Hash Table
Used to compute average items per slot where is the number of keys and is the number of slots.
Double Hashing Probe Sequence
Used to determine the -th probe slot for key in open addressing double hashing.
Worst-case Quicksort Pivot Probability
Used for uniform random pivot selection on distinct elements where minimum and maximum elements yield the most unbalanced split.
Linear Probing Probe Sequence
Used when iteratively resolving collisions by inspecting consecutive cyclic slots.
Expected Slot Occupancy (Load Factor under SUHA)
Used to find the expected number of keys hashing to any specific slot when independent keys are hashed across slots.
Independent Slot Avoidance Probability
Used under SUHA when independent keys must hash exclusively outside a designated subset of slots.
Binary Search Worst-Case Probe Bound
Used to find the minimum number of probes required in the worst case to determine the exact transition index in a sequence of elements with possible outcome states.
Recursive Binary Search Recurrence
Used when analyzing the number of operations or recursive steps executed by binary search on an array of size .
Worst-Case Unbalanced Quick Sort Recurrence
Used to evaluate the worst-case running time of Quick sort under extreme unbalanced pivot partitions.
Shift from standard Big-O identification of basic sorting algorithms towards exact manual tracing (e.g., counting void merges, computing exact probe index in double hashing).
2026, 2025
Increased usage of NAT question formats for hashing and merge computations rather than multiple-choice options.
2026, 2025, 2019, 2015, 2014
Inclusion of non-standard hashing mechanisms, such as MSQs testing trie-like dynamic bit-sliced collision resolution.
2021
Shift from purely single-choice probability or theory questions to procedural tracing and formula evaluation tested via NAT and MSQ formats.
2026, 2020, 2014
Consistent focus on 1-mark foundational conceptual checks, with occasional 2-mark probability/counting questions.
2026, 2023, 2022, 2020, 2014
Direct identification of standard sorting complexities was tested in 1-mark MCQs, while exact decision-tree lower bounds on fixed array sizes appeared as 2-mark NAT questions.
2017, 2016
Questions consistently target divide-and-conquer recurrences ( and ), emphasizing worst-case behavior across recursive search and sort algorithms.
2021, 2016
Easy questions test direct definitions (load factor , maximum swaps in selection sort) or single-concept evaluation (chaining max length on <10 keys). Medium questions involve manual tracing (double hashing probe collisions, merge sort execution on 8 elements, optimal merge tree calculation) or multi-step comparison arithmetic ( bounds, bitonic search multi-phase log analysis).