//generated by GPT-5.4?, modified by hamamu namespace polygonLib{ using ll=long long; template T cross2d(const pair &a,const pair &b){ return a.first*b.second-a.second*b.first; } template T polyArea(const vector> &polygon){ const ll n=(ll)polygon.size(); if(n<=2) return T(); T area2=T(); for(ll i=0;i