import System.IO
import Data.List

yummyAndPoisonedSumUp :: (Int, Int, Int) -> Int
yummyAndPoisonedSumUp tupple = do
  let (yuck, yummy, poisoned) = tupple
  poisoned + yummy

eatableCount :: Int -> Int -> Int -> (Int, Int, Int)
eatableCount yuck yummy poisoned
  | poisoned <= (unpoisoned) = (yuck, yummy, poisoned)
  | poisoned >  (unpoisoned) = (yuck, yummy, unpoisoned + 1)
  where unpoisoned = yuck + yummy


main = do
  args <- getLine
  let stringArray = words args
  let [a, b, c] = [ read numberStr | numberStr <- stringArray ] :: [Int]
  putStr $ show $ yummyAndPoisonedSumUp $ eatableCount a b c


