#include #include #include #include #include #include #define MAXN 50005 using namespace std; struct flower { int minv; int maxv; int a; int b; int c; }; struct incident { int temp; int f; int type; }; int T,N; flower f[MAXN]; incident b[2*MAXN]; void discret() { for(int i=1;i<=N;i++) { b[i*2-1].temp=f[i].minv; b[i*2-1].type=1; b[i*2-1].f=b[i*2].f=i; b[i*2].temp=f[i].maxv; b[i*2].type=2; } } bool mycmp(incident x,incident y) { if(x.tempbest)best=ans; } printf("%lld\n",best); } } int main() { //freopen("1002.in","r",stdin); //freopen("1002.out","w",stdout); solve(); return 0; }