GATE CS 2022 · File Organization & Data Types

MCQ · 1 mark · Problem DBMS-INDX-0041

Suppose we are given \(n\) keys, \(m\) hash table slots, and two simple uniform hash functions \(h_1\) and \(h_2\). Further suppose our hashing scheme uses \(h_1\) for the odd keys and \(h_2\) for the even keys. What is the expected number of keys in a slot?
  1. A
    \(\frac{m}{n}\)
  2. B
    \(\frac{n}{m}\)
  3. C
    \(\frac{2n}{m}\)
  4. D
    \(\frac{n}{2m}\)

Solve it on GATE DA practice →More Storage & Indexing problems

Show the worked solutionOfficial GATE Answer Key: Option B.See full step-by-step discussion on GateOverflow: https://gateoverflow.in/371930/Gate-cse-2022-question-6

GATE DA practice: past exam problems by chapter, with worked solutions · gatedaprep.com