func_code_string: #include <bits/stdc++.h>   using namespace std;   int n, a, b, p[100000], la[100000], lb[100000];   int party[100000];   bool pass, assigned[100000];   map<int, int> m;   inline int deg(int i) { return (la[i] != -1) + (lb[i] != -1); }   int dfs(int i) {     if (deg(i) == 0) {       return 1;     }     if (~la[i]) {       int t = la[i];       la[t] = la[i] = lb[i] = -1;       if (!assigned[i] && (assigned[i] = assigned[t] = 1))         party[i] = party[t] = 0;       if (t == i) pass = 1;       return 1 + dfs(t);     } else {       int t = lb[i];       lb[t] = la[i] = lb[i] = -1;       if (!assigned[i] && (assigned[i] = assigned[t] = 1))         party[i] = party[t] = 1;       if (t == i) pass = 1;       return 1 + dfs(t);     }   }   int main() {     scanf( %d%d%d , &n, &a, &b);     for (int i = 0; i < n; ++i) scanf( %d , p + i), m[p[i]] = i;     auto fd = [](int x) {       auto it = m.find(x);       return it == m.end() ? -1 : it->second;     };     for (int i = 0; i < n; ++i) {       la[i] = fd(a - p[i]);       lb[i] = fd(b - p[i]);       if (deg(i) == 0) {         puts( NO );         return 0;       }     }     for (int i = 0; i < n; ++i) {       if (deg(i) == 1) {         pass = 0;         if (dfs(i) & 1 && !pass) {           puts( NO );           return 0;         }       }     }     for (int i = 0; i < n; ++i) {       if (deg(i) == 2) {         dfs(i);       }     }     puts( YES );     for (int i = 0; i < n; ++i) printf( %d  , party[i]);   }   