import io.StdIn._
object Main extends App {
  val n = readInt
  val b = readLine.split(" ").map(_.toLong).toList

  val res = b.head +
    b.sliding(2)
      .foldLeft(0L)((a, b) => math.min(b(0), b(1)) + a) + b.last
  println(res)
}
