n = gets.to_i if n < 3 puts 0 exit end t = Array.new(n) n.times{|i| t[i] = Array.new(i+1) } t[0][0] = 1 1.upto(n-1){|i| if i % 2 == 1 t[i][0] = 0 1.upto(i){|j| t[i][j] = t[i][j-1] + t[i-1][j-1] } else t[i][i] = 0 (i-1).downto(0){|j| t[i][j] = t[i][j+1] + t[i-1][j] } end } p t[n-1].inject(&:+) * 2 % 1000000007