import sys

input = sys.stdin.readline

INF = 10**18

sys.setrecursionlimit(10**6)

import itertools as it

import collections as cl

from collections import deque

import math

from functools import reduce

from collections import defaultdict

D = 10 ** 9 + 7



def li():

    return [int(x) for x in input().split()]





def modpow(a, n, mod):

    res = 1

    while n > 0:

        if n & 1:

            res = res * a % mod

        a = a * a % mod

        n >>= 1

    return res



N = int(eval(input()))



total = modpow(10, N, D)

A = total - modpow(9, N, D)

B = total - modpow(9, N, D)

C = total - modpow(8, N, D)



ans = (A + B - C) % D

print(ans)
D = 10 ** 9 + 7



def li():

    return [int(x) for x in input().split()]



N = int(eval(input()))



total = pow(10, N, D)

A = total - pow(9, N, D)

B = total - pow(9, N, D)

C = total - pow(8, N, D)



ans = (A + B - C) % D

print(ans)
import sys

input = sys.stdin.readline
INF = 10**18
sys.setrecursionlimit(10**6)
import itertools as it
import collections as cl
from collections import deque
import math
from functools import reduce
from collections import defaultdict

D = 10**9 + 7


def li():
    return [int(x) for x in input().split()]


def modpow(a, n, mod):
    res = 1
    while n > 0:
        if n & 1:
            res = res * a % mod
        a = a * a % mod
        n >>= 1
    return res


N = int(eval(input()))
total = modpow(10, N, D)
A = total - modpow(9, N, D)
B = total - modpow(9, N, D)
C = total - modpow(8, N, D)
ans = (A + B - C) % D
print(ans)

D = 10**9 + 7


def li():
    return [int(x) for x in input().split()]


N = int(eval(input()))
total = pow(10, N, D)
A = total - pow(9, N, D)
B = total - pow(9, N, D)
C = total - pow(8, N, D)
ans = (A + B - C) % D
print(ans)

-import sys - -input = sys.stdin.readline -INF = 10**18 -sys.setrecursionlimit(10**6) -import itertools as it -import collections as cl -from collections import deque -import math -from functools import reduce -from collections import defaultdict - -def modpow(a, n, mod): -    res = 1 -    while n > 0: -        if n & 1: -            res = res * a % mod -        a = a * a % mod -        n >>= 1 -    return res - - -total = modpow(10, N, D) -A = total - modpow(9, N, D) -B = total - modpow(9, N, D) -C = total - modpow(8, N, D) +total = pow(10, N, D) +A = total - pow(9, N, D) +B = total - pow(9, N, D) +C = total - pow(8, N, D)