#include #define ll long long using namespace std; #define rep(i, n) for (int i = 0; i < n; i++) #define rrep(i, n) for (int i = 1; i <= n; i++) ll gcd(ll a, ll b) { return b ? gcd(b, a%b) : a; } ll lcm(ll a, ll b) { return (a * b) / gcd(a,b); } using P = pair ; templatebool chmax(T &a, const T &b) { if (abool chmin(T &a, const T &b) { if (b> n; vector a(n); rep(i,n)cin >> a[i]; int ans = -1; rep(i,n-1){ for(int j = i+1;j