Start here · Essential guide
Sets in C++: How std::set Works
Learn how C++ std::set stores unique values in sorted order, with examples of insert, find, erase, custom comparators, and how it differs from hash sets.
Strings, Containers and Memory
How std::set keeps unique sorted values, with a note on sets in Python.
Start here · Essential guide
Learn how C++ std::set stores unique values in sorted order, with examples of insert, find, erase, custom comparators, and how it differs from hash sets.
No. In Python, set() makes an empty set while {} makes an empty dict. Learn how to tell them apart, create sets correctly and avoid the common mistakes.
Related topics