package main import ( "fmt" "math" "math/big" ) func main() { var n int _, _ = fmt.Scan(&n) mod := int64(math.Pow10(9)) + 7 bi := Pow10Mod793(n) bi.Mul(bi, big.NewInt(12)) bi.Sub(bi, big.NewInt(12)) bi.Div(bi, big.NewInt(9)) bi.Add(bi, big.NewInt(1)) bi.Mod(bi, big.NewInt(mod)) fmt.Println(bi.Int64()) } func Pow10Mod793(n int) *big.Int { if n <= 1 { return big.NewInt(10) } else if n%2 == 1 { bi := Pow10Mod793(n - 1) bi.Mul(bi, big.NewInt(10)) return bi } else { bi := Pow10Mod793(n / 2) bi.Mul(bi, bi) return bi } }