// Compile: g++ -std=c++20 -O2 -Wall -I$HOME/ctf/tools/ac-library -DLOCAL -o sol sol.cpp // Or: make sol (uses Makefile in this dir) // Run: ./sol < in.txt #include #include using namespace std; using namespace atcoder; using ll = long long; using ull = unsigned long long; using vi = vector; using vll = vector; using vvi = vector; using vvll = vector; using pii = pair; using pll = pair; #define rep(i,n) for(ll i=0;i<(ll)(n);++i) #define rep2(i,a,b) for(ll i=(ll)(a);i<(ll)(b);++i) #define all(x) (x).begin(),(x).end() #define rall(x) (x).rbegin(),(x).rend() #define sz(x) ((ll)(x).size()) template bool chmin(T&a,const T&b){if(b bool chmax(T&a,const T&b){if(a