ProgrammingHard

A chained table uses the key modulo 7 for 7 buckets. Keys 3, 10, 17, 24 are inserted. What is the length of bucket 3?

  1. A. 4
  2. B. 3
  3. C. 2
  4. D. 1

Correct answer: A. 4

3, 10, 17 and 24 are all congruent to 3 modulo 7, so they all land in bucket 3.

More C Programming questions

Exams that ask this topic