Problem B
For, against, or on the Fence
Languages
en
is
The current policy of the government can be represented by a point in the plane. A voter’s ideal policy would be represented by the point $(x_v, y_v)$. The voter’s unhappiness with the current policy is measured by the distance between these two points. Many different distance metrics may be used, but we will use squared Euclidean distance here.
The voter’s unhappiness with the current policy is $u$. A new policy is proposed and is put to the vote. Determine the voter’s opinion on the new policy, represented by the point $(x_p, y_p)$. Are they for, against, or on the fence?
Input
The first line contains two integers $x_p$ and $y_p$. The second line contains two integers $x_v$ and $y_v$. The third line contains an integer $u$, where $0 \leq u \leq 4 \cdot 10^{18}$ All coordinates are integers between $-10^9$ and $10^9$, inclusive on both ends.
Output
Output for if the voter would be happier with the newly proposed policy, against if they would be unhappier, or on the fence if they would be equally happy either way.
Sample Input 1 | Sample Output 1 |
---|---|
-8 4 2 -6 200 |
on the fence |
Sample Input 2 | Sample Output 2 |
---|---|
20 -3 20 1 10 |
against |
Sample Input 3 | Sample Output 3 |
---|---|
1 1 0 0 3 |
for |