#include <bits/stdc++.h>
using namespace std;
const long long INF = 1e9 + 7, MOD = 1e9 + 7;
const long long LINF = 1e18;
const long long dx[4] = {1, 0, -1, 0}, dy[4] = {0, 1, 0, -1};
signed main() {
  long long n, k;
  cin >> n >> k;
  for (long long i = 0; i < n; i++) {
    long long a;
    cin >> a;
  }
  if (n <= k) {
    cout << 1 << endl;
    return 0;
  }
  n -= k;
  if (n % (k - 1) == 0)
    cout << 1 + n / (k - 1) << endl;
  else
    cout << n / (k - 1) + 2 << endl;
  return 0;
}
