#include #include #include using namespace atcoder; using mint = modint1000000007; using namespace std; #define rep(i,n) for (int i = 0; i < (n); ++i) #define Inf 1000000000000000000 long long get(long long n){ if(n<0)return 0; return n+1; } int main(){ long long x,y,d; cin>>x>>y>>d; long long ans = get(d); ans -= get(d-(x+1)); ans -= get(d-(y+1)); ans += get(d-(x+y+2)); cout<