#include <bits/stdc++.h>
using namespace std;
const int N = 6666;
int main() {
  double n;
  cin >> n;
  if ((n + 1) / 2 - (int)(n + 1) / 2 >= 0.5)
    cout << (int)((n + 1) / 2 + 1) << endl;
  else
    cout << (int)((n + 1) / 2) << endl;
  return 0;
}
