insert method
- T element
Inserts a new element into the set. Time complexity: O(log N).
Returns true if the element was added, or false if it was already present.
Implementation
bool insert(T element) {
return _container.add(element);
}
Inserts a new element into the set. Time complexity: O(log N).
Returns true if the element was added, or false if it was already present.
bool insert(T element) {
return _container.add(element);
}