#include <bits/stdc++.h>
using namespace std;
set<int> banned_rows, banned_cols;
int n;
vector<bool> rows;
int result = 0;
void process_rows() {
  rows.resize(n);
  for (int i = 1; i < n - 1; i++)
    if (banned_rows.find(i) == banned_rows.end()) {
      rows[i] = true;
      result++;
    }
}
vector<vector<int> > row_directions;
vector<bool> directions;
void process_cols() {
  row_directions.resize(n, vector<int>(2));
  directions.resize(n);
  for (int i = 1; i < n - 1; i++)
    if (banned_cols.find(i) == banned_cols.end()) {
      if (!(n % 2 == 1 && i == n / 2 + 1)) row_directions[i][1]++;
      if (!(n % 2 == 1 && i == n / 2 + 1)) row_directions[n - i - 1][0]++;
    }
  for (int i = 0; i < n / 2 + n % 2; i++) {
    directions[i] = row_directions[i][0] > row_directions[i][1];
    directions[n - i - 1] = !directions[i];
  }
  for (int i = 1; i < n - 1; i++)
    if (banned_cols.find(i) == banned_cols.end()) {
      if ((directions[i] || !rows[i]) &&
          (!directions[n - i - 1] || !rows[n - i - 1]))
        result++;
    }
}
int main() {
  int m;
  cin >> n >> m;
  for (int i = 0; i < m; i++) {
    int r, c;
    cin >> r >> c;
    banned_rows.insert(r - 1);
    banned_cols.insert(c - 1);
  }
  banned_rows.insert(0);
  banned_cols.insert(0);
  banned_rows.insert(n - 1);
  banned_cols.insert(n - 1);
  if (n % 2 == 1 && banned_rows.find(n / 2) == banned_rows.end() &&
      banned_cols.find(n / 2) == banned_cols.end())
    banned_cols.insert(n / 2);
  result = n - banned_rows.size() + n - banned_cols.size();
  cout << result << endl;
}
