template <typename Key, // set::key_type/value_type
typename Compare = std::less<Key>, // set::key_compare/value_compare
typename Alloc = std::allocator<Key> // set::allocator_type
> class set;
Sets are containers that store unique elements following a specific order.
๐ set์ unique element
๋ฅผ ๊ฐ์ง๊ณ ํน์ ์์์ ๋ฐ๋ผ ์ ์ฅํ๋ ์ปจํ
์ด๋
The value of the elements in a set cannot be modified once in the container (the elements are always const), but they can be inserted or removed from the container.
๐ set์ element๋ const์. ์์ ๋ ์ ์์. ๋์ ์ปจํ
์ด๋์์ ์ฝ์
๋๊ฑฐ๋ ์ญ์ ๋ ์๋ ์์.
Sets are typically implemented as binary search trees.
๐ set์ ์ผ๋ฐ์ ์ผ๋ก bst๋ก ๊ตฌํ๋๋ค. gcc์ ๊ฒฝ์ฐ rbtree๋ก ๊ตฌํ๋ผ์์.