func_code_string: #include <bits/stdc++.h>   using namespace std;   int main() {     int n, h;     cin >> n;     int a[n];     cin >> a[0];     h = a[0];     for (int i = 1; i < n; i++) {       cin >> a[i];       h = h + abs(a[i] - a[i - 1]) + 1;     }     cout << h + n;   }   