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

 

 Help authour, Buy PDF Ebook   >>>Click Here<<<

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
Civics Test Questions answers


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
Education Questions answers


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
Civics Test Questions answers


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
Public administration Questions answers


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
Commerce Questions answers


Question 10 Explanation: 
Initially, 58 collides at position 8. Another collision occurs one cell away. Hence, F(i2)=4. Using quadratic probing formula, the location is obtained as 2.

There are 10 questions to complete.

 

 Download all FREE PDF Ebook >>>CLICK HERE<<<