mod = 10**9+7 N = int(input()) ans = 1 + 12 * (pow(10, N , mod) - 1) * pow(9, mod-2, mod) print(ans%mod)