#include <bits/stdc++.h>
using namespace std;
int main() {
  vector<int> a(3, 0);
  cin >> a[0] >> a[1] >> a[2];
  sort(a.begin(), a.end());
  int cnt = 0;
  while (a[0] + a[1] <= a[2]) {
    a[0]++;
    cnt++;
    if (a[0] > a[1]) {
      swap(a[0], a[1]);
    }
  }
  cout << cnt << endl;
  return 0;
}
