{"trustable":true,"prependHtml":"\u003cstyle type\u003d\u0027text/css\u0027\u003e\n .input, .output {\n border: 1px solid #888888;\n }\n .output {\n margin-bottom: 1em;\n position: relative;\n top: -1px;\n }\n .output pre, .input pre {\n background-color: #EFEFEF;\n line-height: 1.25em;\n margin: 0;\n padding: 0.25em;\n }\n \u003c/style\u003e\n \u003clink rel\u003d\"stylesheet\" href\u003d\"//codeforces.org/s/96598/css/problem-statement.css\" type\u003d\"text/css\" /\u003e\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 type\u003d\"text/javascript\" async src\u003d\"https://mathjax.codeforces.org/MathJax.js?config\u003dTeX-AMS_HTML-full\"\u003e\u003c/script\u003e","sections":[{"title":"","value":{"format":"HTML","content":"\u003cp\u003e按位异或是指取两个等长的位模式,并对每对对应位执行逻辑异或操作。如果两个位不同(一个是$$$1$$$,另一个是$$$0$$$),则该位置的结果为$$$1$$$,但如果两个位相同(都是$$$0$$$或都是$$$1$$$),则结果为$$$0$$$。例如,模式$$$0101$$$和$$$1100$$$的按位异或是$$$1001$$$。\u003c/p\u003e\u003cp\u003e在这个问题中,给定$$$3$$$个长度为$$$10$$$位的二进制字符串,其中所有位要么是$$$0$$$,要么是$$$1$$$。你可以无限次交换同一个字符串中的两个位,但不能交换两个不同字符串中的位。\u003c/p\u003e\u003cp\u003e你的任务是重新排列给定字符串中的位,使得重新排列它们的位后的按位异或值尽可能大。你能做到吗?\u003c/p\u003e"}},{"title":"输入","value":{"format":"HTML","content":"\u003cp\u003e第一行包含一个整数$$$T$$$($$$1 \\le T \\le 250$$$),表示测试用例的数量。\u003c/p\u003e\u003cp\u003e每个测试用例由$$$3$$$行组成,每行包含一个长度为$$$10$$$位的二进制字符串,其中所有位要么是$$$0$$$,要么是$$$1$$$。\u003c/p\u003e"}},{"title":"输出","value":{"format":"HTML","content":"\u003cp\u003e对于每个测试用例,输出一行,包含一个长度为$$$10$$$位的二进制字符串,表示重新排列每个字符串的位后可以得到的最大按位异或值。\u003c/p\u003e\u003cp\u003e一个二进制字符串$$$x$$$大于另一个二进制字符串$$$y$$$,如果将这两个字符串转换为十进制表示后,字符串$$$x$$$的十进制值大于字符串$$$y$$$的十进制值。例如,字符串\"\u003cspan class\u003d\"tex-font-style-tt\"\u003e1100\u003c/span\u003e\"大于字符串\"\u003cspan class\u003d\"tex-font-style-tt\"\u003e0101\u003c/span\u003e\",因为它的十进制值$$$12$$$,而字符串\"\u003cspan class\u003d\"tex-font-style-tt\"\u003e0101\u003c/span\u003e\"的十进制值为$$$5$$$。\u003c/p\u003e"}},{"title":"示例 1","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\n0000101011\n0001010101\n0010010000\n1000000010\n0001000100\n1001000000\n\u003c/pre\u003e\u003c/td\u003e\n \u003ctd\u003e\u003cpre\u003e1111111111\n1111110000\n\u003c/pre\u003e\u003c/td\u003e\n \u003c/tr\u003e\n\u003c/tbody\u003e\n\u003c/table\u003e"}},{"title":"注意","value":{"format":"HTML","content":"\u003cp\u003e在第一个测试用例中,你可以按以下方式重新排列给定的字符串:\u003c/p\u003e\u003cul\u003e\u003cli\u003e\"\u003cspan class\u003d\"tex-font-style-tt\"\u003e0000101011\u003c/span\u003e\" $$$\\rightarrow$$$ \"\u003cspan class\u003d\"tex-font-style-tt\"\u003e0000111100\u003c/span\u003e\"\u003c/li\u003e\u003cli\u003e\"\u003cspan class\u003d\"tex-font-style-tt\"\u003e0001010101\u003c/span\u003e\" $$$\\rightarrow$$$ \"\u003cspan class\u003d\"tex-font-style-tt\"\u003e1111000000\u003c/span\u003e\"\u003c/li\u003e\u003cli\u003e\"\u003cspan class\u003d\"tex-font-style-tt\"\u003e0010010000\u003c/span\u003e\" $$$\\rightarrow$$$ \"\u003cspan class\u003d\"tex-font-style-tt\"\u003e0000000011\u003c/span\u003e\"\u003c/li\u003e\u003c/ul\u003e"}}]}