![【Codeforces Round #450 (Div. 2) A】Find Extra One 【Codeforces Round #450 (Div. 2) A】Find Extra One](https://image.shishitao.com:8440/aHR0cHM6Ly9ia3FzaW1nLmlrYWZhbi5jb20vdXBsb2FkL2NoYXRncHQtcy5wbmc%2FIQ%3D%3D.png?!?w=700&webp=1)
【链接】 我是链接,点我呀:)
【题意】
在这里输入题意
【题解】
模拟。
看看Y左边或右边的点个数是否
【代码】
#include <bits/stdc++.h>
using namespace std;
const int N = 1e5;
int a[N+10];
int main(){
#ifdef LOCAL_DEFINE
freopen("F:\\c++source\\rush_in.txt", "r", stdin);
#endif
ios::sync_with_stdio(0),cin.tie(0);
int n;
cin >> n;
for (int i = 1;i <= n;i++){
int y;
cin >> a[i]; cin>>y;
}
sort(a+1,a+1+n);
if (a[n]<0 || a[1] > 0 || (a[1]<0 && a[2]>0) ||(a[n]>0 && a[n-1]<0)){
cout <<"Yes"<<endl;
}else{
cout <<"No"<<endl;
}
return 0;
}