#include <bits/stdc++.h>
using namespace std;
template <class T>
inline void chmin(T& a, T const& b) {
  a = min(a, b);
}
constexpr int INF = 1e9 + 7;
int main() {
  int n;
  cin >> n;
  vector<int> a(n);
  for (int i = 0; (i) < (int)(n); ++(i)) cin >> a[i];
  auto delta = [](int house, int neighbouring) {
    return max(0, neighbouring - house + 1);
  };
  int k_max = (n + 1) / 2;
  vector<array<int, 3> > cur, prv;
  cur.assign(k_max + 1, (array<int, 3>){INF, INF, INF});
  cur[0][0] = 0;
  for (int i = 0; (i) < (int)(n); ++(i)) {
    cur.swap(prv);
    cur.assign(k_max + 1, (array<int, 3>){INF, INF, INF});
    cur[0][0] = 0;
    for (int k = 0; (k) < (int)(k_max); ++(k)) {
      chmin(cur[k + 1][0], prv[k + 1][0]);
      chmin(cur[k + 1][0], prv[k + 1][2]);
      if (i == 0) chmin(cur[k + 1][1], prv[k][0]);
      if (i >= 1) chmin(cur[k + 1][1], prv[k][0] + delta(a[i], a[i - 1]));
      if (i >= 2)
        chmin(cur[k + 1][1],
              prv[k][2] + delta(a[i], min(a[i - 1], a[i - 2] - 1)));
      if (i >= 1) chmin(cur[k + 1][2], prv[k + 1][1] + delta(a[i - 1], a[i]));
    }
  }
  for (int k = (1); (k) < (int)(k_max + 1); ++(k)) {
    cout << *min_element(begin(cur[k]), end(cur[k])) << " ";
  }
  cout << endl;
  return 0;
}
