#include <bits/stdc++.h>
using namespace std;
int main() {
  std::ios::sync_with_stdio(false);
  int a, b, c;
  cin >> a >> b >> c;
  long long int sum_1 = a + b;
  long long int sum_2 = b + c;
  long long int sum_3 = c + a;
  if (sum_1 > c && sum_2 > a && sum_3 > b) {
    cout << 0 << endl;
    return 0;
  }
  if (sum_1 <= c) {
    cout << c - sum_1 + 1 << endl;
    return 0;
  }
  if (sum_2 <= a) {
    cout << a - sum_2 + 1 << endl;
    return 0;
  }
  if (sum_3 <= b) {
    cout << b - sum_3 + 1 << endl;
    return 0;
  }
  return 0;
}
