object Main {

  def main(args: Array[String]): Unit = {
    val N = readLine().toInt
    val Bs = readLine().split(" ").map(_.toInt)

    val As = new Array[Int](Bs.length + 1)
    As(0) = Bs(0)
    As(1) = Bs(0)
    for {
      i <- 1 to Bs.length - 1
    } {
      As(i) = As(i) min Bs(i)
      As(i+1) = Bs(i)
    }

    println(As.sum)
      
  }

}
