n = gets.chomp.to_i

if n < 2
  puts '0'
  exit()
end

rem = n - 2

# # if n > 9
# #   n = 9
# #   rem = 7
# # end

# res = (10**n) - ((8 * 10 + 2 * 9) * 10**rem)

# puts res % (10**9 + 7)

res = 2 * (10**rem)
puts res % (10**9 + 7)