All Questions
Database Indexing hard

Why do many in-memory storage engines (e.g., Redis Sorted Sets, MemTables) use Skip Lists instead of Balanced Trees?

  1. A Skip Lists are mathematically guaranteed to provide constant-time O(1) performance for all find, insert, and delete operations.
  2. B Skip Lists utilize significantly less physical memory than standard B-Trees because they don't require the storage of complex child pointers.
  3. C Skip Lists are significantly easier to implement as lock-free data structures, offering superior write concurrency without complex rebalancing logic.
  4. D Skip Lists are natively cache-oblivious, ensuring that the internal processor cache is always utilized at its maximum theoretical efficiency.

One system design question a day, with spaced repetition so the ones you miss come back.

Get the app

Related questions