# Hash Tables with Quadratic Probing Multiple choice Questions and Answers (MCQs)

## Click on any option to know the CORRECT ANSWERS

 Question 6
How many constraints are to be met to successfully implement quadratic probing?
 A 1 B 2 C 3 D 4

Question 6 Explanation:
2 requirements are to be met with respect to table size. The table size should be a prime number and the table size should not be more than half full.

 Question 7
Which among the following is the best technique to handle collision?
 A Quadratic probing B Linear probing C Double hashing D Separate chaining

Question 7 Explanation:
Quadratic probing handles primary collision occurring in the linear probing method. Although secondary collision occurs in quadratic probing, it can be removed by extra multiplications and divisions.

 Question 8
Which of the following techniques offer better cache performance?
 A Quadratic probing B Linear probing C Double hashing D Rehashing

Question 8 Explanation:
Linear probing offers better cache performance than quadratic probing and also it preserves locality of reference.

 Question 9
What is the formula used in quadratic probing?
 A Hash key = key mod table size B Hash key=(hash(x)+F(i)) mod table size C Hash key=(hash(x)+F(i2)) mod table size D H(x) = x mod 17

Question 9 Explanation:
Hash key=(hash(x)+F(i2)) mod table size is the formula for quadratic probing. Hash key = (hash(x)+F(i)) mod table size is the formula for linear probing.

 Question 10
For the given hash table, in what location will the element 58 be hashed using quadratic probing?

 0 49 1 2 3 4 5 6 7 8 18 9 89
 A 1 B 2 C 7 D 6