/*
 * template.cpp
 *
 *  Created on: 2016/10/30
 *      Author: jin
 */
#define MYDEBUG
#include <iostream>
#include <vector>
#include <cstring>
#include <string>
#include <algorithm>
#include <math.h>


#ifdef MYDEBUG
#define debug(x) cout<<#x<<": "<<x<<endl
#else
#define debug(x)
#endif
#define ll long long
#define ull unsigned long long
#define eps 1e-14
#define all(x) x.begin(), x.end()
using namespace std;

template<typename T>
ostream& operator<<(ostream& out, const vector<T>& v) {
  out << "[";
  size_t last = v.size() - 1;
  for (size_t i = 0; i < v.size(); ++i) {
    out << v[i];
    if (i != last)
      out << ",";
  }
  out << "]";
  return out;
}

class Main {
public:
  void sample() {
    cout << "-------------this is sample program.----------------" << endl;
  }
  
  void ABC047_A(){
	  int a,b,c;
	  cin >> a >> b >> c;
	  if(a==(b+c)) printf("Yes");
	  else if(b==(c+a)) printf("Yes");
	  else if(c==(a+b)) printf("Yes");
	  else printf("No");
  }
  
  void ABC047_B(){
	  int W,H,N;
	  cin >> W >> H >> N;
	  vector<vector<int> > rect();
	  
	  for(int i=0; i<N; ++i){
		  
	  }
  }
  
  void ABC044_A(){
	  int n,k,x,y;
	  cin >> n >> k >> x >> y;
	  int ans;
	  if(n<=k){
		ans = n*x;
	  }else{
		ans = k*x + (n-k)*y;
	  }
	  cout << ans << endl;
  }
  
  void ABC044_B(){
	  string str;
	  cin >> str;
	  vector<int> v(26);
	  std::fill(v.begin(),v.end(),0);
	  for(int i=0; i<str.length(); ++i){
		  v[str[i]-97]++;
	  }
	  for(int i=0; i<v.size(); ++i){
		  if(v[i]%2!=0){
			  cout << "No" << endl;
			  return;
		  }
	  }
	  cout << "Yes" << endl;
  }
  
  void ABC055A(){//割引レストラン
	  int N;
	  cin >> N;
	  cout << N*800 - (N/15)*200 << endl;
  }
  
  void ABC055B(){//総積パワー
	  ull p = 1;
	  int mod = 1000000007;
	  int N;
	  cin >> N;
	  for(int i=1; i<=N; i++){
		  p = p * i % mod;
	  }
	  cout << p << endl;
  }
  void ABC055C(){//吸い殻の吸い殻
	  int N,M;
	  cin >> N >> M;
	  int scc = min(N,M/2);
	  N -= scc;
	  M -= scc * 2;
	  scc += M / 4;
	  cout << scc << endl;
  }
  void ABC055D(){
	  
  }
  void ABC013B(){//錠
	  int a,b;
	  cin >> a >> b;
	  if(b<a) swap(a,b);
	  int x = abs(b-a);
	  int y = abs(b-a-10);
	  cout << min(x,y) << endl;
  }
  void ABC020B(){
	  string a,b;
	  cin >> a >> b;
	  cout << atoi((a+b).c_str())*2 << endl;
  }
  void ABC033A(){
	  int N;
	  cin>>N;
	  cout << (N%1111==0 ? "SAME" : "DIFFERENT") << endl;
  }
  void ABC016B(){
	  int a,b,c;
	  cin >> a >> b >> c;
	  int cp = a+b;
	  int cm = a-b;
	  if(cp==cm&&cp==c) cout << "?" << endl;
	  else if(cp==c) cout <<"+"<<endl;
	  else if(cm==c) cout <<"-"<<endl;
	  else cout <<"!"<<endl;
  }
  void ABC029B(){
	  int ret=0;
	  for(int i=0; i<12; ++i){
		  string s;
		  cin >> s;
		  if(s.find("r")!=string::npos) ret++;
	  }
	  cout << ret << endl;
  }
  void ABC023A(){
	  int x;
	  cin >> x;
	  cout << x/10 + x%10 << endl;
  }
  //t   H D
  //a H H D
  //a D D H
  void ABC056A(){
	  string a,t;
	  cin >> a >> t;
	  string at = a+t;
	  if(at=="HH"||at=="DD") cout << "H" << endl;
	  else cout << "D" << endl;
  }
  void ABC056B(){
	  int W,a,b;
	  cin >> W >> a >> b;
	  if(b<a) swap(a,b);
	  int ans;
	  if(b<=a+W) ans = 0;
	  else{
	    ans = abs(a+W-b);
	  }
	  cout << ans << endl;
  }
};

int main() {
	Main m;
	m.ABC056B();
}


Measured memory_bytes: 256