object Main{
  def main(args:Array[String]) = {
    val sc = new java.util.Scanner(System.in)
    val n,k = sc.nextInt
    val ans = for(i <- 0 to n) yield{
      var x = 1
      for(j <- 1 to i){
        x *= 2
      }
      for(j <- 1 to (n-i)){
        x += k
      }
      x
    }
    println(ans.min)
  }

  def max(a:Int,b:Int):Int = if(a>b) a else b
  def min(a:Int,b:Int):Int = if(a>b) b else a
}
