{"problem":{"name":"Permutation Addition","description":{"content":"You are given a sequence of positive integers: $A=(a_1,\\ldots,a_N)$. Determine whether it is possible to make all elements of $A$ equal by repeating the following operation between $0$ and $10^4$ time","description_type":"Markdown"},"platform":"AtCoder","limit":{"time_limit":2000,"memory_limit":262144},"difficulty":"None","is_remote":true,"is_sync":true,"sync_url":null,"sign":"arc159_c"},"statements":[{"statement_type":"Markdown","content":"You are given a sequence of positive integers: $A=(a_1,\\ldots,a_N)$.\nDetermine whether it is possible to make all elements of $A$ equal by repeating the following operation between $0$ and $10^4$ times, inclusive. If it is possible, show one way to do so.\n\n*   Choose a permutation $(p_1,\\ldots,p_N)$ of $(1,\\ldots,N)$, and replace $A$ with $(a_1+p_1,\\ldots,a_N+p_N)$.\n\n## Constraints\n\n*   $2 \\leq N \\leq 50$\n*   $1 \\leq a_i \\leq 50$\n*   All values in the input are integers.\n\n## Input\n\nThe input is given from Standard Input in the following format:\n\n$N$\n$a_1$ $\\ldots$ $a_N$\n\n[samples]","is_translate":false,"language":"English"}],"meta":{"iden":"arc159_c","tags":[],"sample_group":[["2\n15 9","Yes\n8\n1 2\n1 2\n1 2\n1 2\n2 1\n1 2\n1 2\n1 2\n\nThis sequence of $8$ operations makes $A = (24,24)$, where all elements are equal."],["5\n1 2 3 10 10","No"],["4\n1 1 1 1","Yes\n0\n\nAll elements of $A$ are equal from the beginning."]],"created_at":"2026-03-03 11:01:14"}}