logo

Question detail

A simple hash function is h(key) = key modulo 10. What hash value is produced for the key 47?

Try the question, check the answer, then read the explanation to understand the curriculum point.

At a glance

MCQ

Type

practice

Style

Topic

Hash tables

Exam-style question

Try this first

A simple hash function is h(key) = key modulo 10. What hash value is produced for the key 47?.

  1. A.0
  2. B.4
  3. C.7
  4. D.10

Model answer

What a good answer should say

  • 7

Explanation

Why this works

47 modulo 10 is 7, so the hash value is 7.

Common mistake

No common mistake is linked to this question yet.

Related flashcards

No flashcards are published for this page yet.

Related practice questions

No questions are published for this page yet.