in Programming in C
199 views
0 votes
0 votes

Its answer comes to be in table [5] what should be answer as it starts from 0 then I think answer should be 6 but in test it was given as 5 . please answer 

in Programming in C
199 views

1 comment

5 is correct..

yes it starts from 0 only,its because taking mod with 11 will you give remainder from 0-10 ,

so you will have hashing table with index numbered from 0 to 10.And location is asked where its stored in table so its a[5] only,if its position was asked than it would have been 6
0
0

1 Answer

1 vote
1 vote

Yes 5 is correct. i think u are thinking that if location is starting from 0 then location is 6

but u r thinking on wrong way.Because location is 5 position of that location is 6.

That is last element is situated in 6th position i.e. location 5.

1 comment

if location is asked then it is 5 or position is asked then it is 6 ,thanks for help
0
0