Exam-style question
Try this first
Using h(key) = key modulo 10, which pair of keys causes a collision?.
- A.12 and 23
- B.14 and 25
- C.18 and 28
- D.21 and 32
Answer and explanation
Concise answer
18 and 28
Why this is correct
18 modulo 10 and 28 modulo 10 both produce 8, so these two keys cause a collision.
Use the concise answer above for a quick check, then reveal the full model answer and detailed explanation.
Common mistake
No common mistake is linked to this question yet.
