Doubly linked list - sellout/data-structure-zoo GitHub Wiki

The downside of a doubly linked list as a data structure is that it stores two additional pointers with each node, tripling the in-memory size vs a competing data structure like a dynamic array.

operations

  • [chop back](/sellout/data-structure-zoo/wiki/chop-back) – O(1)
  • [chop front](/sellout/data-structure-zoo/wiki/chop-front) – O(1)
  • [peek back](/sellout/data-structure-zoo/wiki/peek-back) – O(1)
  • [peek front](/sellout/data-structure-zoo/wiki/peek-front) – O(1)
  • [push back](/sellout/data-structure-zoo/wiki/push-back) – O(1)
  • [push front](/sellout/data-structure-zoo/wiki/push-front) – O(1)