{"problem":{"name":"Chmin XOR Game","description":{"content":"Alice and Bob are playing a game using a length-$N$ sequence of non-negative integers $A=(A_1,A_2,\\dots,A_N)$. Starting with Alice, they take turns performing the following operation. The player who c","description_type":"Markdown"},"platform":"AtCoder","limit":{"time_limit":2000,"memory_limit":262144},"difficulty":"None","is_remote":true,"is_sync":true,"sync_url":null,"sign":"arc163_e"},"statements":[{"statement_type":"Markdown","content":"Alice and Bob are playing a game using a length-$N$ sequence of non-negative integers $A=(A_1,A_2,\\dots,A_N)$.\nStarting with Alice, they take turns performing the following operation. The player who cannot make a move first loses.\n\n*   Choose a non-negative integer $X$ such that there is an integer $i$ satisfying $A_i > A_i \\oplus X$.\n*   For each $1 \\le i \\le N$, replace $A_i$ with $\\min(A_i,A_i \\oplus X)$.\n\nDetermine who wins when both players play optimally.\nHere, $\\oplus$ represents the bitwise XOR.\nYou are given $T$ test cases. Find the answer for each of them.\n\n## Constraints\n\n*   $1 \\le T \\le 100$\n*   $1 \\le N \\le 100$\n*   $0 \\le A_i \\le 10^9$\n\n## Input\n\nThe input is given from Standard Input in the following format:\n\n$T$\n$\\mathrm{case}_1$\n$\\mathrm{case}_2$\n$\\vdots$\n$\\mathrm{case}_T$\n\nHere, $\\mathrm{case}_i$ is the $i$\\-th test case. Each test case is given in the following format:\n\n$N$\n$A_1$ $A_2$ $\\dots$ $A_N$\n\n[samples]","is_translate":false,"language":"English"}],"meta":{"iden":"arc163_e","tags":[],"sample_group":[["5\n2\n3 1\n5\n1 1 1 1 1\n4\n0 0 0 0\n4\n8 1 6 4\n5\n3 8 7 12 15","Bob\nAlice\nBob\nBob\nAlice\n\nIn the first test case, one possible game progression could be as follows.\n\n*   Alice chooses $X=3$. This choice is valid because $3 > 3 \\oplus 3(=0)$ for $i=1$.\n*   $A=(3,1)$ becomes $A=(0,1)$.\n*   Bob chooses $X=1$. This choice is valid because $1 > 1 \\oplus 1(=0)$ for $i=2$.\n*   $A=(0,1)$ becomes $A=(0,0)$.\n*   Since Alice cannot choose any $X$, the game ends.\n\nIn this case, Bob wins.\nIn the second test case, one possible game progression could be as follows.\n\n*   Alice chooses $X=1$. This choice is valid because $1 > 1 \\oplus 1(=0)$ for $i=1$.\n*   $A=(1,1,1,1,1)$ becomes $A=(0,0,0,0,0)$.\n*   Since Bob cannot choose any $X$, the game ends.\n\nIn this case, Alice wins."]],"created_at":"2026-03-03 11:01:13"}}