in Databases retagged by
409 views
1 vote
1 vote
Assume that a B-Tree is used as an index for a large database table which has six levels (including the root node). If a new key is inserted into this index, then the maximum number of levels possible in the updated tree is ______.
in Databases retagged by
by
409 views

2 Comments

I think the question should be "Maximum number of level that can form", how could we find maximum number of nodes possible, if order of the node is not given ?
0
0
The question is vague.
0
0

1 Answer

1 vote
1 vote
Best answer
lets take  all the node contain maximum no of keys which can be hold by them , now insert a key in the leaf node then the node will break in two node and transfer one of the key to the parent

but we know that the parent also have maximum keys so adding one key to them will split the node in to two node and one key will be  transfer to the its parent ,again same thing happen

at the end when the key will be inserted in the root node the root node will break and create a new parent which will contain only single key

so one level has been increased

so total level is 7
selected by
Answer:

Related questions