Common data structure to implement relational database

Which is the common data structure to implement a relational database?

Answer: Relational databases commonly uses B-tree indexes for data retrieval.

Time Complexity of B-Tree:

Sr. No. Algorithm Time Complexity
1 Add O(log n)
1 Delete O(log n)
2 Search O(log n)

C++ Program to implement B-tree


Please tell that how much elements you want to insert?2

Please enter the element: 3

Please enter the element: 4

The traversal of constructed B tree is:

3   4