{"trustable":true,"prependHtml":"\u003cscript\u003e window.katexOptions \u003d { disable: true }; \u003c/script\u003e\n\u003cscript type\u003d\"text/x-mathjax-config\"\u003e\n MathJax.Hub.Config({\n tex2jax: {\n inlineMath: [[\u0027$$$\u0027,\u0027$$$\u0027], [\u0027$\u0027,\u0027$\u0027]],\n displayMath: [[\u0027$$$$$$\u0027,\u0027$$$$$$\u0027], [\u0027$$\u0027,\u0027$$\u0027]]\n }\n });\n\u003c/script\u003e\n\u003cscript async src\u003d\"https://mathjax.codeforces.org/MathJax.js?config\u003dTeX-AMS-MML_HTMLorMML\" type\u003d\"text/javascript\"\u003e\u003c/script\u003e","sections":[{"title":"","value":{"format":"HTML","content":"\u003cdiv class\u003d\"panel_content\"\u003e\u003ci\u003ePut simply, the Justice card represents justice, fairness, truth and the law. You are being called to account for your actions and will be judged accordingly. If you have acted in a way that is in alignment with your Higher Self and for the greater good of others, you have nothing to worry about. However, if you have\u003cbr\u003eacted in a way that is out of alignment, you will be called out and required to own up to your actions. If this has you shaking in your boots, know that the Justice card isn’t as black and white as you may think.\u003c/i\u003e\u003cbr\u003e\u003cbr\u003eOn the table there are n weights. On the body of the i-th weight carved a positive integer $k_i$ , indicating that its weight is $\\frac{1}{2^{k_i}}$ gram. Is it possible to divide the n weights into two groups and make sure that the sum of the weights in each group is greater or equal to $\\frac{1}{2}$ gram? That’s on your call. And please tell us how if possible.\u003c/div\u003e"}},{"title":"Input","value":{"format":"HTML","content":"In the first line of the input there is a positive integer $T$ (1 ≤ $T$ ≤ 2000), indicating there are $T$ testcases.\u003cbr\u003eIn the first line of each of the $T$ testcases, there is a positive integer $n$ (1 ≤ $n$ ≤ $10^5$, ∑n ≤ 7 × $10^5$), indicating there are $n$ weights on the table.\u003cbr\u003eIn the next line, there are $n$ integers $k_i$ (1 ≤ ki ≤ $10^9$), indicating the number carved on each weight."}},{"title":"Output","value":{"format":"HTML","content":"For each testcase, first print Case $i$: ANSWER \u003cb\u003ein one line\u003c/b\u003e, $i$ indicating the case number starting from $1$ and ANSWER should be either YES or NO, indicating whether or not it is possible to divide the weights. Pay attention to the space between : and ANSWER.\u003cbr\u003eIf it’s possible, you should continue to output the dividing solution by print a 0/1 string of length $n$ \u003cb\u003ein the next line\u003c/b\u003e. The $i$-th character in the string indicating whether you choose to put the i-th weight in group 0 or group 1."}},{"title":"Sample","value":{"format":"HTML","content":"\u003ctable class\u003d\u0027vjudge_sample\u0027\u003e\n\u003cthead\u003e\n \u003ctr\u003e\n \u003cth\u003eInput\u003c/th\u003e\n \u003cth\u003eOutput\u003c/th\u003e\n \u003c/tr\u003e\n\u003c/thead\u003e\n\u003ctbody\u003e\n \u003ctr\u003e\n \u003ctd\u003e\u003cpre\u003e3\r\n3\r\n2 2 2\r\n3\r\n2 2 1\r\n2\r\n1 1\u003c/pre\u003e\u003c/td\u003e\n \u003ctd\u003e\u003cpre\u003eCase 1: NO\r\nCase 2: YES\r\n001\r\nCase 3: YES\r\n10\u003c/pre\u003e\u003c/td\u003e\n \u003c/tr\u003e\n\u003c/tbody\u003e\n\u003c/table\u003e\n"}}]}