#include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std; int xx,yy,xxx,yyy; int main(){ int n; cin >> n; for(int a0 = 0; a0 < n; a0++){ int x; int y; cin >> x >> y; if (a0==0) { xx=x; yy=y; continue;} if (x!=xx) xxx=1; if (y!=yy) yyy=1; xx=x; yy=y; } if (yyy==1 && xxx==1) cout<<"NO"<