#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e6 + 1;
const int base = 1e9 + 7;
template <typename T>
void Read(T& x) {
  bool Neg = false;
  char c;
  for (c = getchar(); c < '0' || c > '9'; c = getchar())
    if (c == '-') Neg = !Neg;
  x = c - '0';
  for (c = getchar(); c >= '0' && c <= '9'; c = getchar()) x = x * 10 + c - '0';
  if (Neg && x > 0) x = -x;
}
long long power(long long a, long long t) {
  if (t == 1) return a;
  long long c = power(a, t / 2);
  if (t % 2 == 1)
    return ((c * c) % base * a) % base;
  else
    return (c * c) % base;
}
int n, m;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(nullptr);
  int b, g;
  int n;
  cin >> b >> g >> n;
  long long x = 0, y = 0, x1 = 0;
  if (b <= n)
    x = b;
  else
    x = n;
  x1 = n - x;
  if (g <= n)
    y = g;
  else
    y = n;
  cout << abs(y - x1) + 1;
}
