#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m, k;
  cin >> n >> m >> k;
  if (n == 1) {
    cout << m << endl;
    return 0;
  } else if (n == 2) {
    cout << m / 2 + m % 2 << endl;
    return 0;
  }
  int ans = 1;
  m -= n;
  int d = min(k - 1, n - k);
  long long D = (long long)(d + 1) * (long long)(d + 1);
  if ((long long)m < D) {
    cout << 1 + floor(sqrt(m)) << endl;
  } else {
    ans += d + 1;
    m -= (d + 1) * (d + 1);
    d = 2 * d + 2;
    while (d <= n && m >= d) {
      ans++;
      m -= d;
      d++;
    }
    ans += m / n;
    cout << ans << endl;
  }
}
