//#pragma GCC optimize("Ofast,no-stack-protector,unroll-loops,fast-math")
//#pragma GCC target("sse,sse2,sse3,ssse3,sse4.1,sse4.2,avx,avx2,popcnt,tune=native")

//#include <immintrin.h>
//#include <emmintrin.h>
#include <bits/stdc++.h>
using namespace std;
#define rep(i,h,t) for (int i=h;i<=t;i++)
#define dep(i,t,h) for (int i=t;i>=h;i--)
#define ll long long
#define me(x) memset(x,0,sizeof(x))
#define IL inline
#define rint register int
inline ll rd(){
	ll x=0;char c=getchar();bool f=0;
	while(!isdigit(c)){if(c=='-')f=1;c=getchar();}
	while(isdigit(c)){x=(x<<1)+(x<<3)+(c^48);c=getchar();}
	return f?-x:x;
}
char ss[1<<24],*A=ss,*B=ss;
IL char gc()
{
	return A==B&&(B=(A=ss)+fread(ss,1,1<<24,stdin),A==B)?EOF:*A++;
}
template<class T>void maxa(T &x,T y)
{
	if (y>x) x=y;
}
template<class T>void mina(T &x,T y)
{
	if (y<x) x=y;
}
template<class T>void read(T &x)
{
	int f=1,c; while (c=gc(),c<48||c>57) if (c=='-') f=-1; x=(c^48);
	while(c=gc(),c>47&&c<58) x=x*10+(c^48); x*=f;
}
const int mo=1e9+7;
ll fsp(int x,int y)
{
	if (y==1) return x;
	ll ans=fsp(x,y/2);
	ans=ans*ans%mo;
	if (y%2==1) ans=ans*x%mo;
	return ans;
}
struct cp {
	ll x,y;
	cp operator +(cp B)
	{
		return (cp){x+B.x,y+B.y};
	}
	cp operator -(cp B)
	{
		return (cp){x-B.x,y-B.y};
	}
	ll operator *(cp B)
	{
		return x*B.y-y*B.x;
    }
    int half() { return y < 0 || (y == 0 && x < 0); }
};
const int N=3e5;
struct re{
	int a,b,c;
}a[N],b[N];
bool cmp1(re x,re y)
{
	return x.a<y.a;
}
bool cmp2(re x,re y)
{
	return x.b<y.b;
}
int main()
{
   ios::sync_with_stdio(false);
   int n;
   cin>>n;
   int mx1,mx2,mx3,mx4;
   rep(i,1,n)
   {
     cin>>a[i].a>>a[i].b;
     b[i].a=a[i].a; a[i].c=b[i].c=i;
     b[i].b=a[i].b;
   }
   sort(a+1,a+n+1,cmp1);
   sort(b+1,b+n+1,cmp2);
   int ans=0;
   if (a[1].c==b[1].c&&a[n].c==b[n].c)
   {
   	ans=max(a[n].a-a[2].a,a[n-1].a-a[1].a);
   	ans=max(ans,max(b[n].b-b[2].b,b[n-1].b-b[1].b));
   } else
   {
   	 if (a[n].a-a[1].a>b[n].b-b[1].b)
   	 {
   	 	ans=max(max(a[n].a-a[2].a,a[n-1].a-a[1].a),b[n].b-b[1].b);
   	 } else
   	 {
   	 	ans=max(max(b[n].b-b[2].b,b[n-1].b-b[1].b),a[n].a-a[1].a);
   	 }
   }
   cout<<ans<<endl;
   return 0;
}




#include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define rep2(i, j, k) for(int i = j; i < k; i++)
#define print(x) cout << x
#define newline cout << endl
#define space cout << ' '
#define INF 1000000007
using namespace std;
using ll = long long;
using vi = vector<int>;
using vl = vector<ll>;

int main(){
    ll n;
    cin >>n;
    vl x(n);
    vl y(n);
    rep(i,n){
        cin >> x[i];
        cin >> y[i];
    }
    rep(i,n){
        for(int j=i+1;j<n;j++){
            for(int k=j+1;k<n;k++){
                ll e=(x[i]-x[j])*(y[k]-y[i])-(y[i]-y[j])*(x[k]-x[i]);
                if(!e){
                    print("Yes");
                    return 0;
                }
            }
        }
    }
    print("No");
    return 0;
}