def min(i,j); i < j ? i : j ; end
class Row
  def initialize(pat); @pat = pat; end
  def bit?(i); (@pat & (1 << i)) > 0; end
  def valid?; (1 .. W).each_cons(3).none?{|i,j,k| bit?(i - 1) && bit?(j - 1) }; end
  def to(from)
    if from == 1
      bit?(from - 1) ? from + 1 : from
    elsif from == W
      bit?(from - 2) ? from - 1 : from
    else
      bit?(from - 1) ? from + 1 
      : bit?(from - 2) ? from - 1
      : from
    end
  end
end

H, W, K = gets.split.map(&:to_i)
P = (1 << (W - 1)).times.map{|pat| Row.new(pat) }.select(&:valid?)

dp = Array.new(H + 1){ Array.new(W + 1, 0) }
dp[0][1] = 1

(1 .. H).each do |n|
  P.each do |pat|
    (1 .. W).each do |from|
      to = pat.to(from)
      dp[n][to] += dp[n - 1][from]
      dp[n][to] %= 1_000_000_007
    end
  end
end
puts dp[H][K]


