keys = 44,45,79,55,91,18,63
insert one by one, starts with 44
44%7 = 2
insert 45
45%7 = 3
insert 79
79%7 = 2 ---> collision===> check next cell, collision ===> check next cell ===> fit at 4
insert 55
55%7 = 6
0 |
1 |
2 |
3 |
4 |
5 |
6 |
|
|
44 |
45 |
79 |
|
55 |
insert 91
91%7 = 0
0 |
1 |
2 |
3 |
4 |
5 |
6 |
91 |
|
44 |
45 |
79 |
|
55 |
insert 18
18%7 = 4 ---> collision===> check next cell ===> fit at 5
0 |
1 |
2 |
3 |
4 |
5 |
6 |
91 |
|
44 |
45 |
79 |
18 |
55 |
Therefore 18 fits at location 5