#include <bits/stdc++.h>
using namespace std;
long long int inv[1005 + 3];
long long int fact_inv[1005 + 3];
long long int fact[1005 + 3];
void inverse() {
  inv[1] = 1;
  int i;
  for (i = 2; i <= 1005; i++) {
    inv[i] = 1000000007 - (1000000007 / i) * inv[1000000007 % i] % 1000000007;
  }
}
void factinv() {
  int i;
  fact_inv[0] = 1;
  for (i = 1; i <= 1005; i++) {
    fact_inv[i] = fact_inv[i - 1] * inv[i] % 1000000007;
  }
}
void facto() {
  int i;
  fact[0] = 1;
  for (i = 1; i <= 1005; i++) {
    fact[i] = (fact[i - 1] * i) % 1000000007;
  }
}
int main(void) {
  {
    ios_base::sync_with_stdio(false);
    cin.tie(NULL);
  };
  inverse();
  factinv();
  facto();
  int t = 1;
  while (t--) {
    int n, pos, x, cr = 0, l, r, a1 = 0, a2 = 0, i;
    cin >> n >> x >> pos;
    int a[n];
    for (i = 0; i < n; i++) a[i] = i;
    r = n, l = 0;
    while (l < r) {
      int mid = (l + r) / 2;
      if (a[mid] <= pos) {
        a1++;
        l = mid + 1;
      } else {
        a2++;
        r = mid;
      }
    }
    long long int ans = 1;
    if (n - x < a2) ans = 0;
    ans *= fact[n - x];
    ans %= 1000000007;
    ans *= fact_inv[max(n - x - a2, 0)];
    ans %= 1000000007;
    if (x - 1 < a1 - 1) ans = 0;
    ans *= fact[x - 1];
    ans %= 1000000007;
    ans *= fact_inv[max(x - a1, 0)];
    ans %= 1000000007;
    ans *= fact[n - a1 - a2];
    ans %= 1000000007;
    cout << ans;
  }
}
