#include using namespace std; typedef long double ld; typedef long long ll; typedef unsigned long long ull; #define endl "\n" #define MP make_pair #define FOR(i,a,b) for(int i=(a);i<=(b);i++) #define FORR(x,arr) for(auto& x:arr) #define PII pair #define FI first #define SE second #define ALL(x) (x).begin(), (x).end() const int INF=1<<30; const ll LINF=1LL<<60; const ll mod=1e9+7; const int NIL = -1; templateinline bool chmax(T &a, const T &b) { if (ainline bool chmin(T &a, const T &b) { if (b> x >> y >> z; ll ans = z; if(x<=z) ans -= 1; if(y<=z) ans -= 1; cout << ans << endl; return 0; }