Skip to main contentSkip to solution

What will be corresponding index position (List-II) of elements (List-I) in a empty hash table of size 10 using the remainder method?

List-IList-II
ElementIndex Position
(A) 12(I) 6
(B) 57(II) 1
(C) 41(III) 2
(D) 26(IV) 7

Solution

✅ Correct Option: 4

The remainder method uses h(k)=k mod 10h(k) = k \bmod 10, which is the last digit of the key. Since the table is empty and each key has a different last digit, there are no collisions.

List IWorkingList II
(A) 1212 mod 10=212 \bmod 10 = 2(III) 2
(B) 5757 mod 10=757 \bmod 10 = 7(IV) 7
(C) 4141 mod 10=141 \bmod 10 = 1(II) 1
(D) 2626 mod 10=626 \bmod 10 = 6(I) 6

For table size 10, the index is just the units digit of the key.

Keyboard Shortcuts

  • Left arrow: Previous question
  • Right arrow: Next question
  • S key: Jump to solution
  • Q key: Jump to question