#include <bits/stdc++.h>
using namespace std;
int pl = 0, pg = 0, pe = 0;
long long int mod = 1e9 + 7;
long long int power(long long int b, long long int e, long long int m) {
  long long int ans = 1;
  while (e) {
    if (e % 2) ans = (ans * b) % m;
    e >>= 1;
    if (e) b = (b * b) % m;
  }
  return ans;
}
long long int modInverse(long long int a, long long int m) {
  return (long long int)power(a, m - 2, m);
}
long long int ncr(long long int n, long long int r, long long int m) {
  r = min(r, n - r);
  long long int num = 1, den = 1;
  for (long long int i = 0; i < r; i++) {
    num = (num * (n - i)) % m;
    den = (den * (i + 1)) % m;
  }
  return (num * modInverse(den, m)) % m;
}
long long int bs(vector<long long int> &a, long long int x) {
  long long int left = 0;
  long long int right = a.size();
  while (left < right) {
    long long int middle = (left + right) / 2;
    if (a[middle] > x)
      pg++;
    else if (a[middle] < x)
      pl++;
    else
      pe++;
    if (a[middle] <= x)
      left = middle + 1;
    else
      right = middle;
  }
  if (left > 0 && a[left - 1] == x)
    return 1LL;
  else
    return 0LL;
}
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  ;
  long long int t = 1;
  while (t--) {
    long long int n, x, pos;
    cin >> n >> x >> pos;
    vector<long long int> a(n);
    for (long long int i = 0; i < n; i += 1) {
      if (i < pos)
        a[i] = x - 1;
      else if (i == pos)
        a[i] = x;
      else
        a[i] = x + 1;
    }
    bs(a, x);
    long long int ans = 1;
    if (n - x >= pg)
      ans = (ans * ncr(n - x, pg, mod)) % mod;
    else {
      cout << 0;
      break;
    }
    if (x - 1 >= pl)
      ans = (ans * ncr(x - 1, pl, mod)) % mod;
    else {
      cout << 0;
      break;
    }
    for (long long int i = 2; i < pg + 1; i += 1) ans = (ans * i) % mod;
    for (long long int i = 2; i < pl + 1; i += 1) ans = (ans * i) % mod;
    for (long long int i = 2; i < n - pg - pl - pe + 1; i += 1)
      ans = (ans * i) % mod;
    cout << ans;
  }
  return 0;
}
