#include "bits/stdc++.h" #include #include #pragma warning(disable:4996) using namespace std; using ld = long double; template using Table = vector>; void cou(vectorbs) { for (int i = 0; i < bs.size(); ++i) { if (bs[i]) { cout << 'o'; } else { cout << 'x'; } } cout << endl; } vectoras; int main() { long long int N, X; cin >> N >> X; as.resize(N); for (int i = 0; i < N; ++i) { cin >> as[i]; } sort(as.begin(),as.end()); unordered_map>premap; premap[0] = vector(); int now = 0; while (premap.size() < 500000&&now!=N) { unordered_map>newmap(premap); for (auto& i : newmap) { i.second.emplace_back(false); } for (auto i : premap) { i.second.emplace_back(true); newmap[i.first+as[now]] =i.second; } premap = newmap; now++; } if (now == N) { auto ansit = premap.find(X); if (ansit != premap.end()) { cou(ansit->second); } else { cout << "No" << endl; } return 0; } else { map>lastmap; lastmap[0]=vector(); while (now != N) { map>newmap(lastmap); for (auto& i : newmap) { i.second.emplace_back(false); } for (auto i : lastmap) { i.second.emplace_back(true); newmap[i.first + as[now]] = i.second; } lastmap = newmap; now++; } for (const auto& p : premap) { auto ansit = lastmap.find(p.first); if (ansit != lastmap.end()) { vectoransbs(p.second); ansbs.insert(ansbs.end(), ansit->second.begin(), ansit->second.end()); cou(ansit->second); return 0; } } cout << "No" << endl; return 0; } return 0; }