import scala.io.StdIn

object Main extends App {

  val Array(a,b,c) = StdIn.readLine.split(" ").map(_.toInt)

  val ans = if((a+b) >= c) b + c
    else if(b > c) c * 2 + a
    else  b * 2 + a + 1

  println(ans)
}