#include using namespace std; typedef long long ll; typedef unsigned long long ull; typedef pair pii; typedef vector vec; typedef vector vecl; const int INF = 1000000001; const ll INFL = 1000000000000000001; #define loop(i,a,b) for(i=a;i' << #x << '=' << x << endl; #define sz(x) ((int)x.size()) #define si(n) scanf("%d",&n) #define gi(n) printf("%d\n",n) #define sl(n) scanf("%I64d",&n) #define gl(n) printf(" %I64d\n",n) #define sll(n) scanf("%lld",&n) #define gll(n) printf("%lld\n",n) #define nl() printf("\n") #define limit 1000009 #define pi 3.14159 #define fread freopen("abc.txt","r",stdin) #define fwrite freopen("out.txt","w",stdout); int a[100]; int b[100]; int main(){ int n; cin >> n; for(int a0 = 0; a0 < n; a0++){ int x; int y; cin >> x >> y; a[a0]=x; b[a0]=y; } int flag=0; int i=0; for(i=0;i<=n-2;i++) { float x = (float) (b[i+1]-b[i]) /(a[i+1]-a[i]) ; float y = (float) (b[i+2]-b[i+1]) /(a[i+2]-a[i+1]) ; if(x!=y) { flag=1; } } if(flag) cout<<"NO\n"; else cout<<"YES\n"; return 0; }