Elementary Data Structures

This post extracts some knowledge from Introduction to Algorithms Chapter 10 -- Elementary Data Structures.

Introduction

A dynamic set is a collection of elements that changes over time: elements may be added, removed, searched for, or queried in different ways.

CLRS describes several common operations on dynamic sets:

  • SEARCH(S, k): find an element with key k in set S.
  • INSERT(S, x): add element x to set S.
  • DELETE(S, x): remove element x from set S.
  • MINIMUM(S): return the element with the smallest key.
  • MAXIMUM(S): return the element with the largest key.
  • SUCCESSOR(S, x): return the next larger element after x.
  • PREDECESSOR(S, x): return the next smaller element before x.

原文链接:https://zhuang.dev/reading/introduction-to-algorithms/10-elementary-data-structures/

posted @ 2026-08-30 14:13  neozhuang  阅读(4)  评论(0)    收藏  举报