/**
* Author: Oleksandr Bacherikov, chilli
* Date: 2019-05-05
* License: Boost Software License
* Source: https://codeforces.com/blog/entry/48868
* Description: Returns the two points with max distance on a convex hull (ccw,
* no duplicate/collinear points).
* Status: stress-tested, tested on kattis:roberthood
* Time: O(n)
*/#pragma once
#include"src/geometry/Point.h"typedefPoint<ll>P;array<P,2>hullDiameter(vector<P>S){intn=sz(S),j=n<2?0:1;pair<ll,array<P,2>>res({0,{S[0],S[0]}});rep(i,0,j)for(;;j=(j+1)%n){res=max(res,{(S[i]-S[j]).dist2(),{S[i],S[j]}});if((S[(j+1)%n]-S[j]).cross(S[i+1]-S[i])>=0)break;}returnres.second;}
Traceback(mostrecentcalllast):File"/opt/hostedtoolcache/Python/3.14.0/x64/lib/python3.14/site-packages/onlinejudge_verify/documentation/build.py",line71,in_render_source_code_statbundled_code=language.bundle(stat.path,basedir=basedir,options={'include_paths':[basedir]}).decode()~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^File"/opt/hostedtoolcache/Python/3.14.0/x64/lib/python3.14/site-packages/onlinejudge_verify/languages/cplusplus.py",line187,inbundlebundler.update(path)~~~~~~~~~~~~~~^^^^^^File"/opt/hostedtoolcache/Python/3.14.0/x64/lib/python3.14/site-packages/onlinejudge_verify/languages/cplusplus_bundle.py",line312,inupdateraiseBundleErrorAt(path,i+1,"#pragma once found in a non-first line")onlinejudge_verify.languages.cplusplus_bundle.BundleErrorAt:src/geometry/HullDiameter.h:line11:#pragmaoncefoundinanon-firstline