#include <bits/stdc++.h>
using namespace std;
const long long MAXN = 2005;
const long long INF = 0x3f3f3f3f;
const long long LINF = 0x1f3f3f3f3f3f3f3f;
const long long MOD = (long long)1e9 + 7;
const long long OVER_FLOW = 0xffffffff;
long long s, T, n, m, M, k, A, B, p;
long long buf[MAXN];
int main() {
  ios::sync_with_stdio(false);
  cin >> buf[1] >> buf[2] >> buf[3];
  sort(buf + 1, buf + 1 + 3);
  cout << max(0ll, buf[3] - buf[2] - buf[1] + 1) << endl;
  return 0;
}
