#include <bits/stdc++.h>
using namespace std;
long long inf = 2147483647;
const long long ll = 9223372036854775807, ninf = 1000000000;
const double eps = 1e-6;
const long long nll = 1000000000000000000;
class BouncingBalls {
 public:
  double expectedBounces(vector<int> x, int T) {}
};
int main() {
  int a;
  while (cin >> a) {
    int x, y;
    for (int i = 0; i < a + 1; i++) cin >> x >> y;
    cout << (a - 4) / 2 << '\n';
  }
  return 0;
}
