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