#include <bits/stdc++.h>
using namespace std;
const int INF = 2 * 1e9;
const int MXN = 1005;
int n, m;
int g[MXN][MXN];
int sr[MXN], sc[MXN];
int main() {
  ios_base::sync_with_stdio(false);
  cin >> n >> m;
  for (int i = 0; i < m; i++) {
    int r, c;
    cin >> r >> c;
    g[r][c] = 1;
  }
  for (int i = 2; i < n; i++) {
    for (int j = 1; j <= n; j++) {
      sr[i] += g[i][j];
    }
  }
  for (int j = 2; j < n; j++) {
    for (int i = 1; i <= n; i++) {
      sc[j] += g[i][j];
    }
  }
  int res = 0;
  for (int i = 2; i < n; i++) {
    if (sr[i] == 0) res++;
    if (sc[i] == 0) res++;
    if (sr[i] == 0 && sc[i] == 0 && i * 2 - 1 == n) res--;
  }
  cout << res << endl;
  return 0;
}
