erase from set by index code example
Example 1: C++ remove element from set
std::set<int> s {1,2,3};
s.erase(2);
Example 2: std::set remove item
std::set<int> myset;
myset.erase(value);
std::set<int> s {1,2,3};
s.erase(2);
std::set<int> myset;
myset.erase(value);