{"problem":{"name":"Golf","description":{"content":"Jumbo Takahashi will play golf on an infinite two-dimensional grid. The ball is initially at the origin $(0, 0)$, and the goal is a grid point (a point with integer coordinates) $(X, Y)$. In one strok","description_type":"Markdown"},"platform":"AtCoder","limit":{"time_limit":2000,"memory_limit":262144},"difficulty":"None","is_remote":true,"is_sync":true,"sync_url":null,"sign":"abc135_e"},"statements":[{"statement_type":"Markdown","content":"Jumbo Takahashi will play golf on an infinite two-dimensional grid.\nThe ball is initially at the origin $(0, 0)$, and the goal is a grid point (a point with integer coordinates) $(X, Y)$. In one stroke, Jumbo Takahashi can perform the following operation:\n\n*   Choose a grid point whose Manhattan distance from the current position of the ball is $K$, and send the ball to that point.\n\nThe game is finished when the ball reaches the goal, and the score will be the number of strokes so far. Jumbo Takahashi wants to finish the game with the lowest score possible.\nDetermine if the game can be finished. If the answer is yes, find one way to bring the ball to the goal with the lowest score possible.\n\nWhat is Manhattan distance?\n\nThe Manhattan distance between two points $(x_1, y_1)$ and $(x_2, y_2)$ is defined as $|x_1-x_2|+|y_1-y_2|$.\n\n## Constraints\n\n*   All values in input are integers.\n*   $1 \\leq K \\leq 10^9$\n*   $-10^5 \\leq X, Y \\leq 10^5$\n*   $(X, Y) \\neq (0, 0)$\n\n## Input\n\nInput is given from Standard Input in the following format:\n\n$K$\n$X$ $Y$\n\n[samples]","is_translate":false,"language":"English"}],"meta":{"iden":"abc135_e","tags":[],"sample_group":[["11\n-1 2","3\n7 4\n2 10\n-1 2\n\n*   The Manhattan distance between $(0, 0)$ and $(7, 4)$ is $|0-7|+|0-4|=11$.\n*   The Manhattan distance between $(7, 4)$ and $(2, 10)$ is $|7-2|+|4-10|=11$.\n*   The Manhattan distance between $(2, 10)$ and $(-1, 2)$ is $|2-(-1)|+|10-2|=11$.\n\nThus, this play is valid.\nAlso, there is no way to finish the game with less than three strokes."],["4600\n52 149","\\-1"],["4\n9 9","5\n1 3\n4 2\n4 6\n6 8\n9 9"]],"created_at":"2026-03-03 11:01:14"}}