#include #include #include #include #include #include #include #include #include #include static const int MOD = 1000000007; using ll = int64_t; using u32 = uint32_t; using namespace std; template constexpr T INF = ::numeric_limits::max()/32*15+208; #include class xor_shift { uint32_t x, y, z, w; public: xor_shift() : x(static_cast((chrono::system_clock::now().time_since_epoch().count())&((1LL << 32)-1))), y(1068246329), z(321908594), w(1234567890) {}; uint32_t urand(){ uint32_t t; t = x ^ (x << 11); x = y; y = z; z = w; w = (w ^ (w >> 19)) ^ (t ^ (t >> 8)); return w; }; int rand(int n){ if(n < 0) return -rand(-n); uint32_t t = numeric_limits::max()/(n+1)*(n+1); uint32_t e = urand(); while(e >= t) e = urand(); return static_cast(e%(n+1)); } int rand(int a, int b){ if(a > b) swap(a, b); return a+rand(b-a); } }; int main() { int k; cin >> k; vector v((1<