erase method
- K key
Removes the element with the specified key.
Returns true if the key was found and removed, false otherwise.
Implementation
bool erase(K key) {
if (_container.containsKey(key)) {
_container.remove(key);
return true;
}
return false;
}