#include using namespace std; #include using namespace atcoder; using ll = long long; using P = pair; vector a,b; vector

ab; ll n; ll f(ll x){ if(x<1)return 1e15; ll mx = a[0]+b[0]*x;; ll mn = a[0]+b[0]*x;; for(ll i = 0; i> n; a = b = vector(n); for(int i =0;i> a[i] >> b[i]; solve(); }