#include <bits/stdc++.h>
#define endl '\n'
using namespace std;
typedef long long ll;
const int N=2e5+10;
struct node {
ll x,y;
}p[N];
int n;
ll calc(int a,int b,int c)
{
ll x=p[c].x-p[a].x;
ll y=p[c].y-p[a].y;
ll u=p[b].x-p[a].x;
ll v=p[b].y-p[a].y;
ll z=x*v-y*u;
if(z<0) z=-z;
return z;
}
int main()
{
ios::sync_with_stdio(false);
cin.tie(0); cout.tie(0);
int n;
cin>>n;
for(int i=0;i<n;i++) cin>>p[i].x>>p[i].y;
ll ans=9e18;
for(int i=0;i<n;i++)
{
ans=min(ans,calc(i,(i+1)%n,(i+2)%n));
}
cout<<ans<<endl;
return 0;
}
07-30
234
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
11-03