#include <bits/stdc++.h>
using namespace std;
const long long inf = 1e12;
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  int n;
  cin >> n;
  long long a[n];
  for (int q = 0; q < n; q++) {
    cin >> a[q];
  }
  long long dp[2][n + 1][3];
  for (int q = 0; q < 2; q++) {
    for (int w = 0; w < n + 1; w++) {
      for (int e = 0; e < 3; e++) {
        dp[q][w][e] = inf;
      }
    }
  }
  dp[1][0][1] = 0;
  dp[1][1][2] = 0;
  for (int q = 2; q <= n; q++) {
    for (int w = 0; w < n + 1; w++) {
      for (int e = 0; e < 3; e++) {
        dp[0][w][e] = dp[1][w][e];
        dp[1][w][e] = inf;
      }
    }
    dp[1][0][1] = 0;
    for (int w = 1; w <= q - q / 2; w++) {
      dp[1][w][0] =
          min(dp[1][w][0], dp[0][w][2] + max(0LL, a[q - 1] - (a[q - 2] - 1)));
      if (a[q - 1] <= a[q - 2] - 1) {
        dp[1][w][1] = dp[0][w][2];
      }
      dp[1][w][1] = min(dp[1][w][1], min(dp[0][w][0], dp[0][w][1]));
      if (q > 2) {
        int prevhouseheight = min(a[q - 3] - 1, a[q - 2]);
        dp[1][w][2] =
            min(dp[1][w][2],
                dp[0][w - 1][0] + max(0LL, prevhouseheight - (a[q - 1] - 1)));
      }
      dp[1][w][2] = min(dp[1][w][2],
                        dp[0][w - 1][1] + max(0LL, a[q - 2] - (a[q - 1] - 1)));
    }
  }
  for (int q = 1; q <= n - n / 2; q++) {
    cout << min(dp[1][q][0], min((dp[1][q][1]), dp[1][q][2])) << " ";
  }
  cout << "\n";
  return 0;
}
