Category Archives: Advanced Data Structure

B-Tree | Set 1 (Introduction)

B-Tree is a self-balancing search tree. In most of the other self-balancing search trees (like AVL and Red Black Trees), it is assumed that everything is in main memory. To understand use of B-Trees, we must think of huge amount of data that cannot fit in main memory.

Skip List | Set 1 (Introduction)

Can we search in a sorted linked list in better than O(n) time? The worst case search time for a sorted linked list is O(n) as we can only linearly traverse the list and cannot skip nodes while searching.

Implement LRU Cache

How to implement LRU caching scheme? What data structures should be used? We are given total possible page numbers that can be referred. We are also given cache (or memory) size (Number of page frames that cache can hold at a time). The LRU caching scheme is to remove the least recently used frame when… Read More »