def main
  gets
  bs = gets.chomp.split(' ').map(&:to_i)

  sum = 0
  (bs.length + 1).times do |i|
    pre_b = i == 0 ? Float::INFINITY : bs[i-1]
    current_b = i == bs.length ? Float::INFINITY : bs[i]
    sum += [pre_b, current_b].min
  end
  puts sum
end

main if $0 == __FILE__
