#include <bits/stdc++.h>
const int N = 1000001;
using namespace std;
int factorialNumInverse[N + 1];
int naturalNumInverse[N + 1];
int fact[N + 1];
void InverseofNumber(int p) {
  naturalNumInverse[0] = naturalNumInverse[1] = 1;
  for (int i = 2; i <= N; i++)
    naturalNumInverse[i] = naturalNumInverse[p % i] * (p - p / i) % p;
}
void InverseofFactorial(int p) {
  factorialNumInverse[0] = factorialNumInverse[1] = 1;
  for (int i = 2; i <= N; i++)
    factorialNumInverse[i] =
        (naturalNumInverse[i] * factorialNumInverse[i - 1]) % p;
}
void factorial(int p) {
  fact[0] = 1;
  for (int i = 1; i <= N; i++) {
    fact[i] = (fact[i - 1] * i) % p;
  }
}
int Binomial(int N, int R, int p) {
  int ans =
      ((fact[N] * factorialNumInverse[R]) % p * factorialNumInverse[N - R]) % p;
  return ans;
}
long long int mod = 1e9 + 7;
void solve() {
  int n, x, pos;
  cin >> n >> x >> pos;
  int left = 0, right = n;
  long long int ans = 1;
  int leftr = x - 1, rightr = n - x;
  while (left < right) {
    int middle = (left + right) / 2;
    if (middle < pos) {
      ans *= leftr;
      ans %= mod;
      leftr--;
      left = middle + 1;
    } else if (middle > pos) {
      ans *= rightr;
      rightr--;
      ans %= mod;
      right = middle;
    } else {
      left = middle + 1;
    }
  }
  for (int i = rightr + leftr; i >= 1; --i) {
    ans *= i;
    ans %= mod;
  }
  cout << ans << endl;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  int t = 1;
  int p = 1000000007;
  InverseofNumber(p);
  InverseofFactorial(p);
  factorial(p);
  while (t--) {
    solve();
  }
  return 0;
}
