#include #include #include #include #include #include #include #include #include #include #include using namespace std; typedef long long ll; const int mod=1e9+7; int dx[]={1,0,0,-1},dy[]={0,1,-1,0}; //点を表す構造体 struct Point{ int x,y; Point(double x=0,double y=0):x(x),y(y){}; }; //四則演算 Point operator-(Point p1,Point p2){ return Point(p1.x-p2.x,p1.y-p2.y); } //比較演算 bool operator<(Point p1,Point p2){ if(p1.x!=p2.x) return p1.x(Point p1,Point p2){ if(p1.y!=p2.y) return p1.y>(istream&is,Point&p){ is>>p.x>>p.y; return is; } //ベクトルを表す構造体 typedef Point Vector; //ベクトルのノルム double norm(Vector a){ return (ll)a.x*a.x+(ll)a.y*a.y; } //内積 ll dot(Vector a,Vector b){ return(ll)a.x*b.x+(ll)a.y*b.y; } //外積 ll cross(Vector a,Vector b){ return(ll)a.x*b.y-(ll)a.y*b.x; } //多角形を表すクラス typedef vectorPolygon; //入出力 istream&operator>>(istream&is,Polygon&p){ for(auto&x:p) is>>x; return is; } //CCW constexpr int COUNTER_CLOCKWISE=1; constexpr int CLOCKWISE=-1; constexpr int ONLINE_BACK=2; constexpr int ONLINE_FRONT=-2; constexpr int ON_SEGMENT=0; int ccw(Point p0,Point p1,Point p2){ Vector a=p1-p0,b=p2-p0; if(cross(a,b)>0) return COUNTER_CLOCKWISE; if(cross(a,b)<0) return CLOCKWISE; if(dot(a,b)<0) return ONLINE_BACK; if(norm(a)=2&&ccw(u[n-2],u[n-1],s[i])!=CLOCKWISE;n--) u.pop_back(); u.push_back(s[i]); } for(int i=s.size()-3;i>=0;i--){ for(int n=l.size();n>=2&&ccw(l[n-2],l[n-1],s[i])!=CLOCKWISE;n--) l.pop_back(); l.push_back(s[i]); } reverse(l.begin(),l.end()); for(int i=u.size()-2;i>=1;i--) l.push_back(u[i]); return l; } int main(){ int n; cin>>n; Polygon g(n); cin>>g; g=andrewScan(g); ll ans=0; for(auto&x:g) for(auto&y:g) ans=max(ans,cross(x,y)); cout<