#include <bits/stdc++.h>
using namespace std;
void yes() {
  cout << "YES"
       << "\n";
}
void no() {
  cout << "NO"
       << "\n";
}
long long int powmod(long long int x, long long int y, long long int mod) {
  long long int ans = 1;
  while (y) {
    if (y % 2 == 1) {
      ans = (ans * x) % mod;
    }
    x = (x * x) % mod;
    y /= 2;
  }
  return ans;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  long long int n;
  cin >> n;
  vector<long long int> v;
  for (long long int i = 0; i < n; i++) {
    long long int x;
    cin >> x;
    v.push_back(x);
  };
  long long int arr[n];
  for (long long int i = 0; i < n + 1; i++) arr[i] = 0;
  for (long long int i = 0; i < n; i++) arr[v[i]]++;
  vector<long long int> fin;
  for (long long int i = 0; i < n; i++) {
    if (v[i] == 0)
      fin.push_back(-1);
    else if (v[i] % 2 == 0)
      fin.push_back(0);
    else
      fin.push_back(1);
  }
  long long int e = 0;
  long long int o = 0;
  for (long long int i = 1; i < n + 1; i++) {
    if (arr[i] == 0) {
      if (i % 2 == 0)
        e++;
      else
        o++;
    }
  }
  long long int dp[n][e + 5][o + 5][2];
  for (long long int i = 0; i < n; i++) {
    for (long long int j = 0; j < e + 5; j++) {
      for (long long int k = 0; k < o + 5; k++) {
        for (long long int l = 0; l < 2; l++) {
          dp[i][j][k][l] = INT_MAX;
        }
      }
    }
  }
  if (fin[0] != -1) {
    if (fin[0] % 2 == 0) {
      dp[0][e][o][0] = 0;
      dp[0][e][o][1] = INT_MAX;
    } else {
      dp[0][e][o][0] = INT_MAX;
      dp[0][e][o][1] = 0;
    }
  } else {
    dp[0][e - 1][o][0] = 0;
    dp[0][e][o - 1][1] = 0;
  }
  for (long long int i = 1; i < n; i++) {
    for (long long int j = e; j >= 0; j--) {
      for (long long int k = o; k >= 0; k--) {
        if (fin[i] == 0) {
          dp[i][j][k][0] = min(dp[i - 1][j][k][0], dp[i - 1][j][k][1] + 1);
          dp[i][j][k][1] = INT_MAX;
        } else if (fin[i] == 1) {
          dp[i][j][k][0] = INT_MAX;
          dp[i][j][k][1] = min(dp[i - 1][j][k][0] + 1, dp[i - 1][j][k][1]);
        } else {
          if (j - 1 >= 0)
            dp[i][j - 1][k][0] =
                min(dp[i - 1][j][k][0], dp[i - 1][j][k][1] + 1);
          if (k - 1 >= 0)
            dp[i][j][k - 1][1] =
                min(dp[i - 1][j][k][0] + 1, dp[i - 1][j][k][1]);
        }
      }
    }
  }
  cout << min(dp[n - 1][0][0][0], dp[n - 1][0][0][1]) << "\n";
  return 0;
}
