#include <bits/stdc++.h>
using namespace std;
const int N = 1e6 + 5;
const long long mod = 1e9 + 7;
const int oo = 1e9;
int dx[] = {0, 0, 1, -1, 1, -1, 1, -1};
int dy[] = {1, -1, 0, 0, -1, 1, 1, -1};
int n;
int t[N], f[N];
int main() {
  scanf("%d", &n);
  for (int i = 0; i <= n - 1; i++) scanf("%d", &t[i]);
  for (int i = 0; i <= n - 1; i++) {
    int x = min(i, n - i - 1);
    if (t[i] - x > 0) f[t[i] - x]++;
  }
  int ans = 0;
  for (int i = 1; i <= 1e6; i++) ans = max(ans, f[i]);
  printf("%d", n - ans);
}
