#include <bits/stdc++.h>
using namespace std;
const int maxn = 5e3 + 3;
int n, a[maxn], dp[maxn][maxn / 2][2];
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) scanf("%d", &a[i]);
  a[0] = a[n + 1] = -100;
  int m = (n + 1) / 2;
  memset(dp, 0x3f, sizeof dp);
  dp[0][0][0] = 0;
  dp[1][1][1] = 0;
  dp[1][0][0] = 0;
  for (int i = 2; i <= n; i++) {
    dp[i][0][0] = 0;
    for (int j = 1; j <= m; j++) {
      dp[i][j][0] =
          min(dp[i - 1][j][0], dp[i - 1][j][1] + max(a[i] - a[i - 1] + 1, 0));
      int tmp1 = a[i - 1] - min(a[i], a[i - 2]) + 1;
      int tmp2 = a[i - 1] - a[i] + 1;
      dp[i][j][1] = min(dp[i - 2][j - 1][1] + max(tmp1, 0),
                        dp[i - 2][j - 1][0] + max(tmp2, 0));
    }
  }
  for (int i = 1; i < m; i++) printf("%d ", min(dp[n][i][0], dp[n][i][1]));
  printf("%d\n", min(dp[n][m][0], dp[n][m][1]));
  return 0;
}
