Consider a B+ -tree in which the maximum number of keys in a node is 5. What…
2010
Consider a B+ -tree in which the maximum number of keys in a node is 5. What is the minimum number of keys in any non-root node?
- A.
1
- B.
2
- C.
3
- D.
4
Attempted by 249 students.
Show answer & explanation
Correct answer: B
Answer: 2
Reasoning:
Maximum number of keys in a node = 5, so the maximum number of children = 5 + 1 = 6.
Every non-root node must have at least ceil(maximum children / 2) children = ceil(6 / 2) = 3 children.
Minimum number of keys = minimum children - 1 = 3 - 1 = 2.
Note: The root is allowed to have fewer keys, but the question asks about any non-root node.
A video solution is available for this question — log in and enroll to watch it.