{"trustable":true,"prependHtml":"\u003cstyle type\u003d\"text/css\"\u003edd \u003e pre {\n display: block;\n padding: 9.5px;\n margin: 0 0 10px;\n font-size: 13px;\n line-height: 1.42857143;\n word-break: break-all;\n word-wrap: break-word;\n color: #333;\n background-color: #f5f5f5;\n border: 1px solid #ccc;\n border-radius: 4px;\n}\u003c/style\u003e","sections":[{"title":"Description","value":{"format":"HTML","content":"2021. Moving Pebbles\r\nTwo players play the following game. At the beginning of the game they start with n (1\u0026lt;\u003dn\u0026lt;\u003d100000) piles of stones. At each step of the game, the player chooses a pile and remove at least one stone from this pile and move zero or more stones from this pile to any other pile that still has stones. A player loses if he has no more possible moves. Given the initial piles, determine who wins: the first player, or the second player, if both play perfectly. \r\n\r\n\r\n给你N堆Stone,两个人玩游戏.\r\n每次任选一堆,首先拿掉至少一个石头,然后移动任意个石子到任意堆中.\r\n谁不能移动了,谁就输了...\r\n"}},{"title":"Input","value":{"format":"HTML","content":"Each line of input has integers 0 \u0026lt; n \u0026lt;\u003d 100000, followed by n positive integers denoting the initial piles. \r\n\r\n"}},{"title":"Output","value":{"format":"HTML","content":"For each line of input, output \"first player\" if first player can force a win, or \"second player\", if the second player can force a win. \r\n\r\n"}},{"title":"Sample","value":{"format":"HTML","content":"\u003ctable class\u003d\"vjudge_sample\"\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 2 1 3\r\n\r\n\r\n\r\n\u003c/pre\u003e\u003c/td\u003e\n \u003ctd\u003e\u003cpre\u003efirst player\r\n\u003c/pre\u003e\u003c/td\u003e\n \u003c/tr\u003e\n\u003c/tbody\u003e\n\u003c/table\u003e\n"}},{"title":"Hint","value":{"format":"HTML","content":"鸣谢lqp18_31.."}}]}