#include <bits/stdc++.h>
using namespace std;
const int N1 = 2505;
const int inf = 0x3f3f3f3f;
int n, m, ns;
int a[N1 * 2], f[N1 * 2][N1], g[N1];
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) scanf("%d", &a[i]);
  if (n == 1) {
    puts("0");
    return 0;
  }
  memset(f, 0x3f, sizeof(f));
  memset(g, 0x3f, sizeof(g));
  f[0][0] = 0;
  f[1][0] = 0;
  a[0] = a[1] + 1;
  int ma;
  if (a[1] > a[2])
    f[1][1] = 0;
  else
    f[1][1] = a[2] - a[1] + 1;
  for (int i = 2; i <= n; i++) {
    ma = (i & 1) ? i / 2 + 1 : i / 2;
    if (i == 5) n = n;
    f[i][1] = max(0, a[i - 1] - a[i] + 1) + max(0, a[i + 1] - a[i] + 1);
    for (int j = 2; j <= ma; j++) {
      if (a[i - 1] < a[i - 2]) {
        f[i][j] = f[i - 2][j - 1] + max(0, a[i - 1] - a[i] + 1);
      } else {
        f[i][j] = f[i - 2][j - 1] + max(0, (a[i - 2] - 1) - a[i] + 1);
      }
      if (i - 3 >= 0) {
        f[i][j] = min(f[i][j], g[j - 1] + max(0, a[i - 1] - a[i] + 1));
      }
      if (i < n) f[i][j] += max(0, a[i + 1] - a[i] + 1);
    }
    for (int j = 1; j <= ma; j++) g[j] = min(g[j], f[i - 2][j]);
  }
  for (int j = 1; j <= ma; j++) {
    g[j] = min(g[j], min(f[n - 1][j], f[n][j]));
    printf("%d ", g[j]);
  }
  puts("");
  return 0;
}
