
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
n, a, b = map(int, input().split())
mod = pow(10, 9) + 7
 
def comb(N, x):
    numerator = 1
    for i in range(N-x+1, N+1):
        numerator = numerator * i % mod
    denominator = 1
    for j in range(1, x+1):
        denominator = denominator * j % mod
    d = pow(denominator, mod-2, mod)
    return numerator * d
 
a = comb(n, a)
b = comb(n, b)
 
print((pow(2, n, mod) -1 -a -b) % mod) 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 n, a, b = map(int, input().split()) n map(int, input().split()) map int input().split() ().split () input split a b mod = pow(10, 9) + 7 mod pow(10, 9) + 7 pow(10, 9) pow 10 9 7 def comb(N, x):
    numerator = 1
    for i in range(N-x+1, N+1):
        numerator = numerator * i % mod
    denominator = 1
    for j in range(1, x+1):
        denominator = denominator * j % mod
    d = pow(denominator, mod-2, mod)
    return numerator * d
  comb numerator = 1 numerator 1 for i in range(N-x+1, N+1):
        numerator = numerator * i % mod
     i range(N-x+1, N+1) range N-x+1 N-x N x 1 N+1 N 1 numerator = numerator * i % mod numerator numerator * i % mod numerator * i numerator i mod denominator = 1 denominator 1 for j in range(1, x+1):
        denominator = denominator * j % mod
     j range(1, x+1) range 1 x+1 x 1 denominator = denominator * j % mod denominator denominator * j % mod denominator * j denominator j mod d = pow(denominator, mod-2, mod) d pow(denominator, mod-2, mod) pow denominator mod-2 mod 2 mod return numerator * d numerator * d numerator d N N x x a = comb(n, a) a comb(n, a) comb n a b = comb(n, b) b comb(n, b) comb n b print((pow(2, n, mod) -1 -a -b) % mod) print (pow(2, n, mod) -1 -a -b) % mod pow(2, n, mod) -1 -a -b pow(2, n, mod) -1 -a pow(2, n, mod) -1 pow(2, n, mod) pow 2 n mod 1 a b mod b = map(int, input().split()) map(int, input().split()) b b = comb(n, b) comb(n, b) b mod = pow(10, 9) + 7 pow(10, 9) + 7 mod a, b = map(int, input().split()) map(int, input().split()) a def comb(N, x):
    numerator = 1
    for i in range(N-x+1, N+1):
        numerator = numerator * i % mod
    denominator = 1
    for j in range(1, x+1):
        denominator = denominator * j % mod
    d = pow(denominator, mod-2, mod)
    return numerator * d
  def comb(N, x):
    numerator = 1
    for i in range(N-x+1, N+1):
        numerator = numerator * i % mod
    denominator = 1
    for j in range(1, x+1):
        denominator = denominator * j % mod
    d = pow(denominator, mod-2, mod)
    return numerator * d
  comb a = comb(n, a) comb(n, a) a n, a, b = map(int, input().split()) map(int, input().split()) n

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
n, a, b = map(int, input().split())
mod = pow(10, 9) + 7
 
def comb(N, x):
    numerator = 1
    for i in range(N-x+1, N+1):
        numerator = numerator * i % mod
    denominator = 1
    for j in range(1, x+1):
        denominator = denominator * j % mod
    d = pow(denominator, mod-2, mod)
    return numerator * d
 
a = comb(n, a)
b = comb(n, b)
 
print((pow(2, n, mod) -1 -a -b) % mod)