Consider a double hashing scheme in which the primary hash function is h_{1}(k) = k mod 23, and the secondary hash function is h_{2}(k) = 1+(k mod 19). Assume that the table size is 23. Then the address returned by probe 1 in the probe sequence (assume that the probe sequence begins at probe 0) for key value k = 90 is ________ .

**Note –** This question was Numerical Type.

**(A)** 13

**(B)** 15

**(C)** 21

**(D)** 23

**Answer:** **(A)** **Explanation:** Given,

Table size = 23, key value k = 90, And, probe i = 1 (probe 1 in the probe sequence)

According to double hashing, we use the formula as,

(h_{1}(k) + i*h_{1}(k)) mod (table size)

where i denotes probe value.

Now,

h_{1}(k) = k mod 23 = 90 mod 23 = 21 And, h_{2}(k) = 1+(k mod 19) = 1+(90 mod 19) = 15

Using to double hashing,

= (h_{1}(k) + i*h_{1}(k)) mod (table size) = (21 + 15) mod 23 = 36 mod 23 = 13

Option (A) is correct.

Quiz of this Question

## Recommended Posts:

- GATE | GATE CS 2020 | Question 40
- GATE | Sudo GATE 2020 Mock III (24 January 2019) | Question 15
- GATE | Sudo GATE 2020 Mock III (24 January 2019) | Question 16
- GATE | Sudo GATE 2020 Mock III (24 January 2019) | Question 17
- GATE | Sudo GATE 2020 Mock III (24 January 2019) | Question 18
- GATE | Sudo GATE 2020 Mock III (24 January 2019) | Question 19
- GATE | Sudo GATE 2020 Mock III (24 January 2019) | Question 20
- GATE | Sudo GATE 2020 Mock III (24 January 2019) | Question 21
- GATE | Sudo GATE 2020 Mock III (24 January 2019) | Question 22
- GATE | Sudo GATE 2020 Mock I (27 December 2019) | Question 47
- GATE | Sudo GATE 2020 Mock I (27 December 2019) | Question 48
- GATE | Sudo GATE 2020 Mock I (27 December 2019) | Question 49
- GATE | Sudo GATE 2020 Mock II (10 January 2019) | Question 22
- GATE | Sudo GATE 2020 Mock I (27 December 2019) | Question 1
- GATE | Sudo GATE 2020 Mock I (27 December 2019) | Question 2
- GATE | Sudo GATE 2020 Mock I (27 December 2019) | Question 3
- GATE | Sudo GATE 2020 Mock I (27 December 2019) | Question 4
- GATE | Sudo GATE 2020 Mock I (27 December 2019) | Question 5
- GATE | Sudo GATE 2020 Mock I (27 December 2019) | Question 6
- GATE | Sudo GATE 2020 Mock I (27 December 2019) | Question 7