{"trustable":true,"prependHtml":"\u003cstyle type\u003d\"text/css\"\u003e\n .markdown img {\n max-width: 900px;\n display: block;\n margin: 10px auto;\n }\n .markdown code {\n display: inline-block;\n padding: 0 4px;\n margin: 0;\n background-color: rgba(0, 0, 0, 0.04);\n border-radius: 3px;\n font-weight: bold;\n }\n .markdown pre code {\n display: block;\n padding: 20px;\n font-weight: normal;\n }\n .markdown table {\n width: 100%;\n table-layout: fixed;\n border-collapse: collapse;\n }\n .markdown table th {\n font-size: 13px;\n text-align: left;\n padding: 10px;\n border: 1px solid #e0e0e0;\n background: #f1f1f1;\n }\n .markdown table td {\n font-size: 14px;\n padding: 5px 10px;\n border: 1px solid #e0e0e0;\n }\n .markdown-form-widget .markdown-notice p {\n padding: 0;\n margin: 0;\n color: #999999;\n font-size: 11px;\n }\n\u003c/style\u003e\n","sections":[{"title":"","value":{"format":"HTML","content":"\u003cdiv class\u003d\"latex latex-raw\"\u003eConsider the set of integers \u003cstrong\u003e\\{0, 1, 2, ..., 2^n-1\\\u003c/strong\u003e}. Your task is to divide it into two sets, \u003cstrong\u003eA\u003c/strong\u003e and \u003cstrong\u003eB\u003c/strong\u003e, so that the sums of \u003cstrong\u003ek\u003c/strong\u003e^\\{th \\}powers of elements in these sets are equal, or report that such a division is impossible.\u003cp\u003e\u003c/p\u003e\n\n\u003cp\u003eIn this problem, we assume that \u003cstrong\u003e0^0 \u003d 1\u003c/strong\u003e.\u003c/p\u003e\n\n\u003cp\u003e\u003c/p\u003e\u003ch2\u003eInput\u003c/h2\u003e\u003cp\u003e\u003c/p\u003e\n\n\u003cp\u003eThe only line of input contains two integers \u003cstrong\u003en\u003c/strong\u003e and \u003cstrong\u003ek\u003c/strong\u003e (\u003cstrong\u003e0\u003c/strong\u003e ≤ \u003cstrong\u003ek\u003c/strong\u003e \u0026lt; \u003cstrong\u003en\u003c/strong\u003e ≤ \u003cstrong\u003e16\u003c/strong\u003e).\u003c/p\u003e\n\n\u003cp\u003e\u003c/p\u003e\u003ch2\u003eOutput\u003c/h2\u003e\u003cp\u003e\u003c/p\u003e\n\n\u003cp\u003eIf a solution exists, print \u003cstrong\u003e2^n\u003c/strong\u003e letters without spaces on a single line: for each integer from \u003cstrong\u003e0\u003c/strong\u003e to \u003cstrong\u003e2^n-1\u003c/strong\u003e, print the name of the set in which you put it (letter \u003cstrong\u003eA\u003c/strong\u003e\u0026#x11; or \u003cstrong\u003eB\u003c/strong\u003e\u0026#x11;). If there is more than one possible solution, print any one of them. If the division is impossible, print \u0026#x10;\u003cstrong\u003eNO SOLUTION\u0026#x11;\u003c/strong\u003e on a single line instead.\u003c/p\u003e\n\n\u003c/div\u003e"}},{"title":"Example","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\u003e2 1\n\u003c/pre\u003e\u003c/td\u003e\n \u003ctd\u003e\u003cpre\u003eABBA\n\u003c/pre\u003e\u003c/td\u003e\n \u003c/tr\u003e\n\u003c/tbody\u003e\n\u003c/table\u003e\n"}}]}