main :: IO ()
main = do
  [w,a,b] <- map read . words <$> getLine :: IO [Int]
  print $ shift w a b
   
shift :: Int -> Int -> Int -> Int
shift w a b 
  |(a + w) < b = b - (a + w)
  |(b + w) < a = a - (b + w)
  |otherwise = 0

