6,422 views
1 votes
1 votes

Given has table uses (key % table size) as hashing function. If linear probing is used, how many collisions are occured on inserting values 10, 5 and 15?

A. 2

B. 3

C. 0

D. None of these

2 Answers

Best answer
5 votes
5 votes

7 collision.

selected by
1 votes
1 votes
0 72
1 15
2 18
3 43
4 36
5 10
6 6
7 5

For key 10 :-collision occured at - 2,3,4

For Key 5:-collision occured at - 6,7

For Key 15:-collision occured at - 7,1

Total Number Of collision occured =3+2+2=7

Hence,Option(B) none of these.

edited by

Related questions

0 votes
0 votes
1 answer
1
tishhaagrawal asked Dec 16, 2023
354 views
Below is my approach to solving this question, can anyone please explain if I am doing it the right way?Let X = #free slotssince, m =7 and n = 3So, $4 \leqslant x\leqsla...
2 votes
2 votes
1 answer
3