#include <bits/stdc++.h>
using namespace std;
const int maxn = (4000000) + 7;
const int inf = (1e9) + 7;
const long long LLinf = (1e18) + 7;
const long long mod = 1e9 + 7;
int main() {
  int n;
  scanf("%d", &n);
  n++;
  n /= 2;
  n--;
  printf("%d", n);
  return 0;
}
