8template <
class T,
class C1,
class A1,
class U>
9inline auto operator|=(std::set<T, C1, A1> &a, U &b) ->
decltype(b.begin(), a) {
10 for (
auto &el : b) a.insert(el);
13template <
class T,
class C1,
class A1,
class U>
14inline auto operator-=(std::set<T, C1, A1> &a, U &b) ->
decltype(b.begin(), a) {
15 for (
auto &el : b) a.erase(el);
18template <
class T,
class C1,
class A1,
class U>
19inline auto operator&=(std::set<T, C1, A1> &a, U &b) ->
decltype(b.begin(), a) {
20 for (
auto it = a.begin(); it != a.end();) {
29template <
class T,
class C1,
class A1,
class U>
30inline auto contains(std::set<T, C1, A1> &a, U &b) ->
decltype(b.begin(),
true) {
32 if (!a.count(el)) return false;
35template <
class T,
class C1,
class A1,
class U>
36inline auto intersects(std::set<T, C1, A1> &a, U &b) ->
decltype(b.begin(),
true) {
38 if (a.count(el)) return true;