#include <bits/stdc++.h>

typedef long long ll;

using namespace std;

#define swap(a, b)    do { typeof(a) __tmp = (a); (a) = (b); (b) = __tmp; } while(0)
#define repd(i, a, b) for(typeof(b) i = a; i < (b); ++i)
#define rep(i, n)     repd(i, 0, n)
#define dump(x)       cerr << #x << " = " << (x) << endl
#define debug(x)      cerr << "L" << __LINE__ << ": " << #x << " = " << (x) << endl
#define YesNo(x) cout << ((x) ? "Yes" : "No") << endl
#define YESNO(x) cout << ((x) ? "YES" : "NO") << endl

class modint {
private:
	std::int64_t number;
	static const std::int64_t modulo;
public:
	modint() : number(0) {}
	modint(const std::uint64_t new_number) { set(new_number); }
	modint(const modint& m) : number(m.number) {}

	void set(const std::int64_t new_number) { number = new_number % modulo; if(number < 0) number += modulo; }
	std::int64_t get() const { return number; }

	modint operator++(int) { modint ret = *this; ++(*this); return ret; } // Postfix Increment
	modint operator--(int) { modint ret = *this; --(*this); return ret; } // Postfix Decrement
	modint& operator++() { *this += 1; return *this; } // Prefix Increment
	modint& operator--() { *this -= 1; return *this; } // Prefix Decrement

	bool operator!() const noexcept { return !static_cast<bool>(*this); } // Logical Not
	modint operator+() const { return *this; }                                 // Unary Plus
	modint operator-() const { modint ret(*this);ret.set(-number);return ret;} // Unary Negation
	explicit operator std::int64_t() const noexcept{ return number; }      // Cast
	explicit operator bool()         const noexcept{ return number != 0; } // Cast

	modint& operator=(const std::int64_t i) { set(i); return *this; }

	modint operator*=(const modint& m) { set(number * m.number); return *this; }
	modint operator/=(const modint& m) { *this *= modint::inv(m); return *this; }
	modint operator%=(const modint& m) { set(number % m.number); return *this; }
	modint operator+=(const modint& m) { set(number + m.number); return *this; }
	modint operator-=(const modint& m) { set(number - m.number); return *this; }
	modint operator*=(const std::int64_t& i) { set(number * i); return *this; }
	modint operator/=(const std::int64_t& i) { *this /= modint(i); return *this; }
	modint operator%=(const std::int64_t& i) { set(number % i); return *this; }
	modint operator+=(const std::int64_t& i) { set(number + i); return *this; }
	modint operator-=(const std::int64_t& i) { set(number - i); return *this; }

	static modint pow(const modint& m1, const modint& m2) {
		std::int64_t base     = m1.get();
		std::int64_t exponent = m2.get();
		std::int64_t ret = 1;

		//if(exponent == 0)      return modint(1);
		//else if(exponent == 1) return modint(base);
		//else if(base == 0)     return modint(0);
		//else if(base == 1)     return modint(1);

		while(exponent > 0) {
			if(exponent & 1) ret = (ret * base) % modulo;
			base = (base * base) % modulo;
			exponent >>= 1;
		}

		return modint(ret);
	}

	/* Inverce Element */
	static modint inv(const modint& m) {
		std::int64_t a = m.get();
		std::int64_t b = modulo;
		std::int64_t u = 1;
		std::int64_t v = 0;

		std::int64_t aa = a;

		while(b != 0) {
			std::int64_t t = a / b;
			a -= t * b;
			swap(a, b);
			u -= t * v;
			swap(u, v);
		}

		modint ret(u);
		return ret;
	}
};

const std::int64_t modint::modulo = 1000000007;
/* Arithmetic */
const modint operator*(const modint& m1, const modint& m2) { return modint(m1) *= m2; }
const modint operator/(const modint& m1, const modint& m2) { return modint(m1) /= m2; }
const modint operator%(const modint& m1, const modint& m2) { return modint(m1) %= m2; }
const modint operator+(const modint& m1, const modint& m2) { return modint(m1) += m2; }
const modint operator-(const modint& m1, const modint& m2) { return modint(m1) -= m2; }
const modint operator*(const modint& m, const std::int64_t& i) { return modint(m) *= i; }
const modint operator/(const modint& m, const std::int64_t& i) { return modint(m) /= i; }
const modint operator%(const modint& m, const std::int64_t& i) { return modint(m) %= i; }
const modint operator+(const modint& m, const std::int64_t& i) { return modint(m) += i; }
const modint operator-(const modint& m, const std::int64_t& i) { return modint(m) -= i; }
const modint operator*(const std::int64_t& i, const modint& m) { return modint(i) *= m; }
const modint operator/(const std::int64_t& i, const modint& m) { return modint(i) /= m; }
const modint operator%(const std::int64_t& i, const modint& m) { return modint(i) %= m; }
const modint operator+(const std::int64_t& i, const modint& m) { return modint(i) += m; }
const modint operator-(const std::int64_t& i, const modint& m) { return modint(i) -= m; }
/* Shift (iostream) */
std::ostream& operator<<(std::ostream& os, const modint m) { os << m.get(); return os; }
std::istream& operator>>(std::istream& is, modint m) { std::int64_t i; is >> i; m.set(i); return is; }
/* Compare */
bool operator<(const modint& m1, const modint& m2) { return m1.get() < m2.get(); }
bool operator>(const modint& m1, const modint& m2) { return m2 < m1; }
bool operator<=(const modint& m1, const modint& m2) { return !(m1 > m2); }
bool operator>=(const modint& m1, const modint& m2) { return !(m1 < m2); }
bool operator==(const modint& m1, const modint& m2) { return !(m1 < m2) && !(m1 > m2); }
bool operator!=(const modint& m1, const modint& m2) { return !(m1 == m2); }
/* Power (exil implementation) */
modint operator^(const modint& m1, const modint& m2) { return modint::pow(m1, m2); }
modint operator^(const modint& m, const std::int64_t& i) { return modint::pow(m, modint(i)); }
modint operator^(const std::int64_t& i, const modint& m) { return modint::pow(modint(i), m); }

typedef modint mi;

bool is_valid(ll n) {
	for(bool flag = false; n != 0; n >>= 1) {
		if(flag && (n & 1)) return false;
		flag = (n & 1);
	}
	return true;
}

int main(int argc, const char* argv[]) {
	ll h, w, k;
	cin >> h >> w >> k;

	if(w == 1) {
		cout << "1" << endl;
		return 0;
	} else if(w == 2) {
		cout << (modint(2) ^ modint(h - 1)) << endl;
		return 0;
	}

	ll b[1 << (w-1)];
	ll bn = 0;
	rep(i, 1 << (w-1)) {
		if(is_valid(i)) {
			b[bn] = i;
			++bn;
		}
	}

	modint a[h+1][w+2];
	
	rep(i, w+2) a[0][i] = 0;
	a[0][1] = 1;
	

	repd(i, 1, h+1) {
		repd(j, 1, w+1) {
			rep(k, bn) {
				ll tmpbar = (b[k] << 1);

				if(tmpbar & (1 << j)) {
					a[i][j] += a[i-1][j+1];
				} else if(tmpbar & (1 << (j-1))) {
					a[i][j] += a[i-1][j-1];
				} else {
					a[i][j] += a[i-1][j];
				}
			}
		}
	}

	cout << a[h][k] << endl;

	return 0;
}


Measured memory_bytes: 256