{"problem":{"name":"Make 10","description":{"content":"We have $N_2$ sticks of length $2$ each, $N_3$ sticks of length $3$ each, and $N_4$ sticks of length $4$ each. You can do the following operation any number of times. *   Choose two sticks. *   Let $","description_type":"Markdown"},"platform":"AtCoder","limit":{"time_limit":2000,"memory_limit":262144},"difficulty":"None","is_remote":true,"is_sync":true,"sync_url":null,"sign":"arc126_a"},"statements":[{"statement_type":"Markdown","content":"We have $N_2$ sticks of length $2$ each, $N_3$ sticks of length $3$ each, and $N_4$ sticks of length $4$ each. You can do the following operation any number of times.\n\n*   Choose two sticks.\n*   Let $x$ and $y$ be the lengths of these sticks. Bond them to form a stick of length $x+y$.\n\nFind the maximum number of sticks that can be made whose lengths are exactly $10$.\nGiven $T$ test cases, solve each of them.\n\n## Constraints\n\n*   $1\\leq T\\leq 100$\n*   $0\\leq N_2, N_3, N_4\\leq 10^{15}$\n\n## Input\n\nInput is given from Standard Input in the following format:\n\n$T$\n$\\text{case}_1$\n$\\text{case}_2$\n$\\vdots$\n$\\text{case}_T$\n\nEach case is in the following format:\n\n$N_2$ $N_3$ $N_4$\n\n[samples]","is_translate":false,"language":"English"}],"meta":{"iden":"arc126_a","tags":[],"sample_group":[["5\n3 4 1\n7 0 0\n0 0 7\n0 0 0\n1000000000000000 1000000000000000 1000000000000000","2\n1\n0\n0\n900000000000000\n\nLet us describe the first case. We have three sticks of length $2$, four sticks of length $3$, and one stick of length $4$.\nOne way to make two sticks of length exactly $10$ is as follows.\n\n*   Bond four sticks of length $2$, $2$, $3$, $3$ in some order to make one stick of length $10$.\n*   Bond three sticks of length $3$, $3$, $4$ in some order to make one stick of length $10$.\n*   Now we have three sticks of length $2$, $10$, $10$."]],"created_at":"2026-03-03 11:01:14"}}