#include <bits/stdc++.h>
using namespace std;
int n;
int dp[101][51][51][2];
vector<int> v, vv;
int isok(int pos, int odd, int even, int before) {
  if (pos == n) return 0;
  int &ans = dp[pos][odd][even][before];
  if (ans != -1) return ans;
  ans = 1e8;
  if (pos == 0) {
    if (v[pos])
      ans = min(ans, isok(pos + 1, odd, even, v[pos] % 2));
    else {
      if (odd) ans = min(ans, isok(pos + 1, odd - 1, even, 1));
      if (even) ans = min(ans, isok(pos + 1, odd, even - 1, 0));
    }
  } else {
    if (v[pos])
      ans = min(ans,
                isok(pos + 1, odd, even, v[pos] % 2) + (before != v[pos] % 2));
    else {
      if (odd) ans = min(ans, isok(pos + 1, odd - 1, even, 1) + (before != 1));
      if (even) ans = min(ans, isok(pos + 1, odd, even - 1, 0) + (before != 0));
    }
  }
  return ans;
}
int main() {
  memset(dp, -1, sizeof(dp));
  cin >> n;
  v.resize(n);
  vv.resize(n + 1);
  for (auto &c : v) cin >> c, vv[c]++;
  int odd = 0, even = 0;
  for (int i = 1; i <= n; i++) {
    if (vv[i]) continue;
    if (i % 2)
      odd++;
    else
      even++;
  }
  cout << isok(0, odd, even, 0);
}
