#include <bits/stdc++.h>
using namespace std;
long long int k = pow(10, 9) + 7;
long long int fac[1000 + 1];
long long int power(long long int x, long long int y) {
  long long int res = 1;
  x = x % k;
  while (y > 0) {
    if (y & 1) res = (res * x) % k;
    y = y >> 1;
    x = (x * x) % k;
  }
  return res;
}
long long int modInverse(long long int n) { return power(n, k - 2); }
long long int nCr(long long int n, long long int r) {
  if (n < r) return 0;
  if (r == 0) return 1;
  return (fac[n] * modInverse(fac[r]) % k * modInverse(fac[n - r]) % k) % k;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  fac[0] = 1;
  for (int i = 1; i <= 1000; i++) fac[i] = (fac[i - 1] * i) % k;
  long long int t = 1;
  while (t--) {
    long long int n, x, pos;
    cin >> n >> x >> pos;
    int left = 0;
    int right = n;
    int middle;
    int x1 = 0, y = 0;
    while (left < right) {
      middle = (left + right) / 2;
      if (pos >= middle) {
        if (pos > middle) x1++;
        left = middle + 1;
      } else {
        y++;
        right = middle;
      }
    }
    int n1 = x - 1;
    int n2 = n - x;
    long long int ans = nCr(n1, x1);
    ans *= fac[x1];
    ans %= k;
    ans *= nCr(n2, y);
    ans %= k;
    ans *= fac[y];
    ans %= k;
    ans *= fac[n - 1 - x1 - y];
    ans %= k;
    cout << ans;
    cout << "\n";
  }
  return 0;
}
