AT_abc485_a.Same Side
入门
通过率:0%
时间限制:2.00s
内存限制:1024MB
AC君温馨提醒
该题目为【atcoder】题库的题目,您提交的代码将被提交至atcoder进行远程评测,并由ACGO抓取测评结果后进行展示。由于远程测评的测评机由其他平台提供,我们无法保证该服务的稳定性,若提交后无反应,请等待一段时间后再进行重试。
题目描述
There is a road that runs straight east and west, and positions on the road are represented by coordinates whose positive direction is east.
Takahashi's house is at coordinate 0, the supermarket is at coordinate A, and the station is at coordinate B. Here, the coordinates of Takahashi's house, the supermarket, and the station are pairwise distinct.
Print Yes if the supermarket and the station are in the same direction from Takahashi's house, and No otherwise.
有一条东西走向的笔直道路,道路上的位置用坐标表示,正方向为东。
高桥的家位于坐标 0,超市位于坐标 A,车站位于坐标 B。其中,高桥的家、超市和车站的坐标两两互不相同。
如果超市和车站位于高桥家的同一侧(即同为东侧或同为西侧),则输出 Yes;否则输出 No。
输入格式
The input is given from Standard Input in the following format:
A B
输入从标准输入中以如下格式给出:
A B
输出格式
Print Yes or No according to the instructions in the problem statement.
根据题目描述中的指示,输出 Yes 或 No。
输入输出样例
输入#1
40 -20
输出#1
No
输入#2
-3 -5
输出#2
Yes
输入#3
9 19
输出#3
Yes
说明/提示
Sample 1 Explanation:
The supermarket and the station are in opposite directions from Takahashi's house.
Constraints
- −100≤A,B≤100
- A=0
- B=0
- A=B
- All input values are integers.
样例 1 解释:
超市和车站位于高桥家的相反方向。
约束条件
- −100≤A,B≤100
- A=0
- B=0
- A=B
- 所有输入值均为整数。
输入解题思路,AI测评打分。不知道怎么写?