Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Leer Challenge: Build a Simple B-Tree | Indexing and Search Structures
Practice
Projects
Quizzes & Challenges
Quizzes
Challenges
/
Data Structures and Algorithms for Scalable Systems

bookChallenge: Build a Simple B-Tree

Taak

Swipe to start coding

In this challenge, you will implement a simplified B-Tree — a balanced search tree widely used in databases and file systems.

Your task is to complete the implementation so that the tree supports:

insert(key):

  • Inserts a new key into the B-Tree.
  • Splits nodes when they overflow to maintain B-Tree properties.
  • The root must split correctly when full.
  • Insertion must always place keys in sorted order.

search(key):

  • Returns True if the key is present in the B-Tree.
  • Returns False if the key is not found.

Additional Rules:

  • The minimum degree t determines the minimum/maximum number of keys in each node.
  • You do not need to implement deletion or disk storage.
  • The tree must correctly handle multiple insertions and node splits.

Oplossing

Was alles duidelijk?

Hoe kunnen we het verbeteren?

Bedankt voor je feedback!

Sectie 2. Hoofdstuk 4
single

single

Vraag AI

expand

Vraag AI

ChatGPT

Vraag wat u wilt of probeer een van de voorgestelde vragen om onze chat te starten.

close

bookChallenge: Build a Simple B-Tree

Veeg om het menu te tonen

Taak

Swipe to start coding

In this challenge, you will implement a simplified B-Tree — a balanced search tree widely used in databases and file systems.

Your task is to complete the implementation so that the tree supports:

insert(key):

  • Inserts a new key into the B-Tree.
  • Splits nodes when they overflow to maintain B-Tree properties.
  • The root must split correctly when full.
  • Insertion must always place keys in sorted order.

search(key):

  • Returns True if the key is present in the B-Tree.
  • Returns False if the key is not found.

Additional Rules:

  • The minimum degree t determines the minimum/maximum number of keys in each node.
  • You do not need to implement deletion or disk storage.
  • The tree must correctly handle multiple insertions and node splits.

Oplossing

Switch to desktopSchakel over naar desktop voor praktijkervaringGa verder vanaf waar je bent met een van de onderstaande opties
Was alles duidelijk?

Hoe kunnen we het verbeteren?

Bedankt voor je feedback!

Sectie 2. Hoofdstuk 4
single

single

some-alt