#P6819. [PA 2012] Binary Dodgeball
[PA 2012] Binary Dodgeball
Description
There are boxes. At the beginning, each box contains one piece.
Two players take turns. Each move, a player may choose a piece in box and a positive integer , and move the piece to the box numbered . If the box numbered already contains a piece, then both pieces are removed from the box. The player who cannot make a move loses.
Find the -th smallest such that the second player can win the game.
Input Format
Only one line, containing one positive integer .
Output Format
Only one line, containing one positive integer .
2
10
Hint
For of the testdata, .
Translated by ChatGPT 5
京公网安备 11011102002149号