criyle/codenet-compile-errors huggingface dataset:
Language: C

#include <stdio.h>
#include <math.h>

int main(void){
    int i,j,n,a,b,x=1;
    int c=1;
    scanf("%d %d %d\n",&n,&a,&b);
    
    if(n%2==0){
        for(i=1;i<=n/2;i++){
            c*=(n+1-i)/i;
        }
        x+=c;
        
        for (j=1;j<n/2;i++){
            c=1;
            for(i=1;i<=j;i++){
                c*=(n+1-i)/i;
            }
            x+=2*c;
        }
        
    }else{
        for (j=1;j<n/2;i++){
            c=1;
            for(i=1;i<=j;i++){
                c*=(n+1-i)/i;
            }
            x+=2*c;
        }
    }
    
    int ca=1;
    for(i=1;i<=a;i++){
        ca*=(n+1-i)/i;
    }
    int cb=0;
    for(i=1;i<=b;i++){
        cb*=(n+1-i)/i;
    }
    x-ca-cb;
    printf("%d\n",x);
    

Compiler output:
main.c: In function 'main':
main.c:42:5: error: expected declaration or statement at end of input
   42 |     printf("%d\n",x);
      |     ^~~~~~
Language: C++

#include <iostream>
#include <algorithm>
#include <vector>
#include <cstdio>
#include <chrono>
#include <utility>
#include <string>
#include <cmath>

#define rep(i, n, m) for(int i = (n); (i) < (m); (i)++)
#define len(arr) sizeof(arr) / sizeof(*arr)

#define ll long long

using namespace std;

//const long long mod = 1000000007;








const int MAX = 1000000000;
const int MOD = 1000000007;

long long fac[MAX], finv[MAX], inv[MAX];

// テーブルを作る前処理
void COMinit() {
    fac[0] = fac[1] = 1;
    finv[0] = finv[1] = 1;
    inv[1] = 1;
    for (int i = 2; i < MAX; i++){
        fac[i] = fac[i - 1] * i % MOD;
        inv[i] = MOD - inv[MOD%i] * (MOD / i) % MOD;
        finv[i] = finv[i - 1] * inv[i] % MOD;
    }
}

// 二項係数計算
long long COM(int n, int k){
    if (n < k) return 0;
    if (n < 0 || k < 0) return 0;
    return fac[n] * (finv[k] * finv[n - k] % MOD) % MOD;
}


int main() {
    cin.tie(0);
    ios::sync_with_stdio(false);

    long long n, a, b;
    cin >> n >> a >> b;

    COMinit();

    long long nca = COM(n, a);
    long long ncb = COM(n, b);
    long long ans = pow(2, n);
    ans -= 1 + nca + ncb;
    ans %= MOD;
    cout << ans << endl;
    return 0;
}

Compiler output:
/tmp/ccvYNZN3.o: in function `COMinit()':
a.cc:(.text+0x20): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccvYNZN3.o
a.cc:(.text+0x2b): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccvYNZN3.o
a.cc:(.text+0x32): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccvYNZN3.o
a.cc:(.text+0x39): relocation truncated to fit: R_X86_64_PC32 against symbol `inv' defined in .bss section in /tmp/ccvYNZN3.o
a.cc:(.text+0xd4): relocation truncated to fit: R_X86_64_PC32 against symbol `inv' defined in .bss section in /tmp/ccvYNZN3.o
a.cc:(.text+0x135): relocation truncated to fit: R_X86_64_PC32 against symbol `inv' defined in .bss section in /tmp/ccvYNZN3.o
a.cc:(.text+0x150): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccvYNZN3.o
a.cc:(.text+0x168): relocation truncated to fit: R_X86_64_PC32 against symbol `inv' defined in .bss section in /tmp/ccvYNZN3.o
a.cc:(.text+0x1b7): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccvYNZN3.o
/tmp/ccvYNZN3.o: in function `COM(int, int)':
a.cc:(.text+0x22e): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccvYNZN3.o
a.cc:(.text+0x249): additional relocation overflows omitted from the output
collect2: error: ld returned 1 exit status
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main(){
  long long n, a, b, s;
  s = 0;
  cin >> n >> a >> b;
  long long v[1e8 + 1][1e8 + 1];
  for(int i = 0; i < n; i++){
    v[i][0] = 1;
    v[i][i] = 1;
  }
  for(int i = 2; i < n; i++){
    for(int j = 1; j < i; j++){
      v[i][j] = (v[i - 1][j - 1] + v[i - 1][j]) % (1e9 + 7);
    }
  }
  v[n - 1][a] = 0;
  v[n - 1][b] = 0;
  for(int i = 0; i < n; i++){
    s = s + v[n - 1][i];
    s = s % (1e9 + 7);
  }
  cout << s << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:28: error: conversion from 'double' to 'long unsigned int' in a converted constant expression
    8 |   long long v[1e8 + 1][1e8 + 1];
      |                        ~~~~^~~
a.cc:8:28: error: could not convert '(1.0e+8 + (double)1)' from 'double' to 'long unsigned int'
    8 |   long long v[1e8 + 1][1e8 + 1];
      |                        ~~~~^~~
      |                            |
      |                            double
a.cc:8:28: error: size of array 'v' has non-integral type 'double'
a.cc:8:19: error: conversion from 'double' to 'long unsigned int' in a converted constant expression
    8 |   long long v[1e8 + 1][1e8 + 1];
      |               ~~~~^~~
a.cc:8:19: error: could not convert '(1.0e+8 + (double)1)' from 'double' to 'long unsigned int'
    8 |   long long v[1e8 + 1][1e8 + 1];
      |               ~~~~^~~
      |                   |
      |                   double
a.cc:8:19: error: size of array 'v' has non-integral type 'double'
a.cc:15:49: error: invalid operands of types 'long long int' and 'double' to binary 'operator%'
   15 |       v[i][j] = (v[i - 1][j - 1] + v[i - 1][j]) % (1e9 + 7);
      |                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^ ~~~~~~~~~
      |                                  |                     |
      |                                  long long int         double
a.cc:22:11: error: invalid operands of types 'long long int' and 'double' to binary 'operator%'
   22 |     s = s % (1e9 + 7);
      |         ~ ^ ~~~~~~~~~
      |         |        |
      |         |        double
      |         long long int
Language: C++

#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const int MAX = 500000;
const int MOD = 1000000007;

ll fac[MAX], finv[MAX], inv[MAX];
void COMinit() {
    fac[0] = fac[1] = 1;
    finv[0] = finv[1] = 1;
    inv[1] = 1;
    for (int i = 2; i < MAX; i++){
        fac[i] = fac[i - 1] * i % MOD;
        inv[i] = MOD - inv[MOD%i] * (MOD / i) % MOD;
        finv[i] = finv[i - 1] * inv[i] % MOD;
    }
}
ll COM(ll n,ll k) {
    ll ret = 1;
    for(ll i=0;i<k;i++) ret = (ret*(n-i))%MOD;
    return (ret * finv[k])%MOD;
}
ll RepeatSquaring(ll N, ll P){
    if(P==0) return 1;
    if(P%2==0){
        ll t = RepeatSquaring(N, P/2);
        return t*t % MOD;
    }
    return N * RepeatSquaring(N, P-1);
}
int main(){
    COMinit();
   ll n,a,b;
   cin >> n >> a >> b;
   ll ans = RepeatSquaring(2,n)-COM(n,a)-COM(n,b)-1;
   while(ans<0) ans += MOD;
   cout << ans << endl;


Compiler output:
a.cc: In function 'int main()':
a.cc:37:24: error: expected '}' at end of input
   37 |    cout << ans << endl;
      |                        ^
a.cc:31:11: note: to match this '{'
   31 | int main(){
      |           ^
Language: C++

#include <algorithm>
#include <iostream>
#include <iomanip>
#include <cassert>
#include <cstring>
#include <string>
#include <vector>
#include <random>
#include <bitset>
#include <queue>
#include <cmath>
#include <unordered_map>
#include <set>
#include <map>
#define rep(i,n) for (int i=0; i<n;++i)
#define ALL(a)  (a).begin(),(a).end()
#define rep_itr(it, M) for (auto it = M.begin(); it != M.end(); ++it)
typedef long long ll;
using namespace std;
const ll MOD = 1e9+7LL;
int N, A,B;
ll pow2mod[1000000004];
ll kaizyoMod[20005];

ll modpow(ll a, ll n) {
    ll res = 1;
    while (n > 0) {
        if (n & 1) res = res * a % MOD;
        a = a * a % MOD;
        n >>= 1;
    }
    return res;
}

// a^{-1} mod を計算する
ll modinv(ll a) {
    return modpow(a, MOD - 2);
}

void kaizyo() {
  ll a = 1ll;
  rep(i, N) {
    ll b = i+1;
    if (i!=0) a = kaizyoMod[i-1]*b;
    kaizyoMod[i] = a;
    kaizyoMod[i]%=MOD;
  }
}


int main() {
  cin.sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);

  cin >> N >> A >> B;
  ll ans = 1ll;
  rep(i, N) {
    ans*=2;
    ans%=MOD;
    pow2mod[i] = ans;
  }
  kaizyo();
  ll inv_a = kaizyoMod[N-1]*modinv(kaizyoMod[A-1])*modinv(kaizyoMod[N-A-1])% MOD;
  ll inv_b = kaizyoMod[N-1]*modinv(kaizyoMod[B-1])*modinv(kaizyoMod[N-B-1])% MOD;
  cout << kaizyoMod[N-1] << "\n";
  cout << pow2mod[N-1] << ' ' << inv_a <<  ' ' << inv_b << "\n";
  cout << (pow2mod[N-1]-inv_a-inv_b-1)%MOD << "\n";
  return 0;
}

Compiler output:
/tmp/ccLAKtnC.o: in function `kaizyo()':
a.cc:(.text+0x123): relocation truncated to fit: R_X86_64_PC32 against symbol `kaizyoMod' defined in .bss section in /tmp/ccLAKtnC.o
a.cc:(.text+0x147): relocation truncated to fit: R_X86_64_PC32 against symbol `kaizyoMod' defined in .bss section in /tmp/ccLAKtnC.o
a.cc:(.text+0x163): relocation truncated to fit: R_X86_64_PC32 against symbol `kaizyoMod' defined in .bss section in /tmp/ccLAKtnC.o
a.cc:(.text+0x1ab): relocation truncated to fit: R_X86_64_PC32 against symbol `kaizyoMod' defined in .bss section in /tmp/ccLAKtnC.o
/tmp/ccLAKtnC.o: in function `main':
a.cc:(.text+0x2dd): relocation truncated to fit: R_X86_64_PC32 against symbol `kaizyoMod' defined in .bss section in /tmp/ccLAKtnC.o
a.cc:(.text+0x2fb): relocation truncated to fit: R_X86_64_PC32 against symbol `kaizyoMod' defined in .bss section in /tmp/ccLAKtnC.o
a.cc:(.text+0x32d): relocation truncated to fit: R_X86_64_PC32 against symbol `kaizyoMod' defined in .bss section in /tmp/ccLAKtnC.o
a.cc:(.text+0x395): relocation truncated to fit: R_X86_64_PC32 against symbol `kaizyoMod' defined in .bss section in /tmp/ccLAKtnC.o
a.cc:(.text+0x3b3): relocation truncated to fit: R_X86_64_PC32 against symbol `kaizyoMod' defined in .bss section in /tmp/ccLAKtnC.o
a.cc:(.text+0x3e5): relocation truncated to fit: R_X86_64_PC32 against symbol `kaizyoMod' defined in .bss section in /tmp/ccLAKtnC.o
a.cc:(.text+0x44d): additional relocation overflows omitted from the output
collect2: error: ld returned 1 exit status
Language: Java

import java.util.*;

public class Flowers {

    private static class Descending implements Comparator<Integer> {
        @Override
        public int compare(Integer i, Integer j) {
            return j - i;
        }
    }

    public static void main(String[] args) {
        Scanner stdin = new Scanner(System.in);
        int n = stdin.nextInt();
        int k = stdin.nextInt();
        Integer[] prices = new Integer[n];
        for(int i = 0; i < n; i++) {
            prices[i] = stdin.nextInt();
        }
        Arrays.sort(prices, new Descending());
        int sum = 0;
        for(int i = 0; i < n; i++) {
            int factor = i / k;
            sum += prices[i] * (factor + 1);
        }
        System.out.println(sum);
        stdin.close();
    }
}

Compiler output:
Main.java:3: error: class Flowers is public, should be declared in a file named Flowers.java
public class Flowers {
       ^
1 error
Language: Java

package Samples;

import java.util.Scanner;

/**
 * Created by eulyanenkov on 02.02.14.
 */
public class Flowers {

    public static void main( String args[] ){

        Scanner in = new Scanner(System.in);

        int N, K;
        N = in.nextInt();
        K = in.nextInt();

        int C[] = new int[N];
        for(int i=0; i<N; i++){
            C[i] = in.nextInt();
        }

        System.out.println(solution(C,K));
    }

    public static int solution(int[] C, int K){

        int total = 0;
        int factor = 1;

        quickSort(C, 0, C.length - 1);

        int buyer = 1;
        for (int i = C.length - 1; i >= 0; i--){
            if (buyer > K){
                factor++;
                buyer = 1;
            }
            total += (C[i] * factor);
            buyer++;
        }

        return total;
    }

    private static void quickSort(int[] A, int low, int high) {
        int i = low, j = high;
        // Get the pivot element from the middle of the list
        int pivot = A[low + (high-low)/2];

        // Divide into two lists
        while (i <= j) {
            // If the current value from the left list is smaller then the pivot
            // element then get the next element from the left list
            while (A[i] < pivot) {
                i++;
            }
            // If the current value from the right list is larger then the pivot
            // element then get the next element from the right list
            while (A[j] > pivot) {
                j--;
            }

            // If we have found a values in the left list which is larger then
            // the pivot element and if we have found a value in the right list
            // which is smaller then the pivot element then we exchange the
            // values.
            // As we are done we can increase i and j
            if (i <= j) {
                int tmp = A[i];
                A[i] = A[j];
                A[j] = tmp;
                i++;
                j--;
            }
        }
        // Recursion
        if (low < j)
            quickSort(A, low, j);
        if (i < high)
            quickSort(A, i, high);
    }
}

Compiler output:
Main.java:8: error: class Flowers is public, should be declared in a file named Flowers.java
public class Flowers {
       ^
1 error
Language: C++

#include <algorithm>
#include <iostream>
#include <iomanip>
#include <cassert>
#include <cstring>
#include <string>
#include <vector>
#include <random>
#include <bitset>
#include <queue>
#include <cmath>
#include <unordered_map>
#include <set>
#include <map>
#define rep(i,n) for (int i=0; i<n;++i)
#define ALL(a)  (a).begin(),(a).end()
#define rep_itr(it, M) for (auto it = M.begin(); it != M.end(); ++it)
typedef long long ll;
using namespace std;
const ll MOD = 1e9+7LL;
int N, A,B;
ll pow2mod[1000000004];
ll kaizyoMod[1000000004];

ll modpow(ll a, ll n) {
    ll res = 1;
    while (n > 0) {
        if (n & 1) res = res * a % MOD;
        a = a * a % MOD;
        n >>= 1;
    }
    return res;
}

// a^{-1} mod を計算する
ll modinv(ll a) {
    return modpow(a, MOD - 2);
}

void kaizyo() {
  ll a = 1ll;
  rep(i, N) {
    ll b = i+1;
    if (i!=0) a = kaizyoMod[i-1]*b;
    kaizyoMod[i] = a;
    kaizyoMod[i]%=MOD;
  }
}


int main() {
  cin.sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);

  cin >> N >> A >> B;
  ll ans = 1ll;
  rep(i, N) {
    ans*=2;
    ans%=MOD;
    pow2mod[i] = ans;
  }
  kaizyo();
  ll inv_a = kaizyoMod[N-1]*modinv(kaizyoMod[A-1])*modinv(kaizyoMod[N-A-1])% MOD;
  ll inv_b = kaizyoMod[N-1]*modinv(kaizyoMod[B-1])*modinv(kaizyoMod[N-B-1])% MOD;
  cout << kaizyoMod[N-1] << "\n";
  cout << pow2mod[N-1] << ' ' << inv_a <<  ' ' << inv_b << "\n";
  cout << (pow2mod[N-1]-inv_a-inv_b-1)%MOD << "\n";
  return 0;
}

Compiler output:
/tmp/ccy1agKi.o: in function `kaizyo()':
a.cc:(.text+0x123): relocation truncated to fit: R_X86_64_PC32 against symbol `kaizyoMod' defined in .bss section in /tmp/ccy1agKi.o
a.cc:(.text+0x147): relocation truncated to fit: R_X86_64_PC32 against symbol `kaizyoMod' defined in .bss section in /tmp/ccy1agKi.o
a.cc:(.text+0x163): relocation truncated to fit: R_X86_64_PC32 against symbol `kaizyoMod' defined in .bss section in /tmp/ccy1agKi.o
a.cc:(.text+0x1ab): relocation truncated to fit: R_X86_64_PC32 against symbol `kaizyoMod' defined in .bss section in /tmp/ccy1agKi.o
/tmp/ccy1agKi.o: in function `main':
a.cc:(.text+0x2dd): relocation truncated to fit: R_X86_64_PC32 against symbol `kaizyoMod' defined in .bss section in /tmp/ccy1agKi.o
a.cc:(.text+0x2fb): relocation truncated to fit: R_X86_64_PC32 against symbol `kaizyoMod' defined in .bss section in /tmp/ccy1agKi.o
a.cc:(.text+0x32d): relocation truncated to fit: R_X86_64_PC32 against symbol `kaizyoMod' defined in .bss section in /tmp/ccy1agKi.o
a.cc:(.text+0x395): relocation truncated to fit: R_X86_64_PC32 against symbol `kaizyoMod' defined in .bss section in /tmp/ccy1agKi.o
a.cc:(.text+0x3b3): relocation truncated to fit: R_X86_64_PC32 against symbol `kaizyoMod' defined in .bss section in /tmp/ccy1agKi.o
a.cc:(.text+0x3e5): relocation truncated to fit: R_X86_64_PC32 against symbol `kaizyoMod' defined in .bss section in /tmp/ccy1agKi.o
a.cc:(.text+0x44d): additional relocation overflows omitted from the output
collect2: error: ld returned 1 exit status
Language: C++

#include <bits/stdc++.h>
using namespace std;

int main(){
  long long n, a, b, s;
  s = 0;
  cin >> n >> a >> b;
  vector<<vector<long long>> v(n, vector<int>(2, 0));
  for(int i = 0; i < n; i++){
    v[i][0] = 1;
    v[i][i] = 1;
  }
  for(int i = 2; i < n; i++){
    for(int j = 1; j < i; j++){
      v[i][j] = v[i - 1][j - 1] + v[i - 1][j] % (1e9 + 7);
    }
  }
  v[n - 1][a] = 0;
  v[n - 1][b] = 0;
  for(int i = 0; i < n; i++){
    s = s + v[n - 1][i];
    s = s % (1e9 + 7);
  }
  cout << s << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:9: error: expected unqualified-id before '<<' token
    8 |   vector<<vector<long long>> v(n, vector<int>(2, 0));
      |         ^~
a.cc:10:5: error: 'v' was not declared in this scope
   10 |     v[i][0] = 1;
      |     ^
a.cc:15:7: error: 'v' was not declared in this scope
   15 |       v[i][j] = v[i - 1][j - 1] + v[i - 1][j] % (1e9 + 7);
      |       ^
a.cc:18:3: error: 'v' was not declared in this scope
   18 |   v[n - 1][a] = 0;
      |   ^
a.cc:22:11: error: invalid operands of types 'long long int' and 'double' to binary 'operator%'
   22 |     s = s % (1e9 + 7);
      |         ~ ^ ~~~~~~~~~
      |         |        |
      |         |        double
      |         long long int
Language: C++

#include<iostream>
#include<iomanip>
#include<vector>
#include<map>
#include<set>
#include<algorithm>
#include<numeric>
#include<limits>
#include<bitset>
#include<functional>
#include<type_traits>
#include<queue>
#include<stack>
#include<array>
#include<random>
#include<utility>
#include<cstdlib>
#include<ctime>
#include <numeric>
#include <stdio.h>
#include<cassert>
using namespace std;
typedef long long ll;
// auto mod int
// https://youtu.be/L8grWxBlIZ4?t=9858
// https://youtu.be/ERZuLAxZffQ?t=4807 : optimize
// https://youtu.be/8uowVvQ_-Mo?t=1329 : division
const int mod = 1000000007;
struct mint {
  ll x; // typedef long long ll;
  mint(ll x=0):x((x%mod+mod)%mod){}
  mint& operator+=(const mint a) {
    if ((x += a.x) >= mod) x -= mod;
    return *this;
  }
  mint& operator-=(const mint a) {
    if ((x += mod-a.x) >= mod) x -= mod;
    return *this;
  }
  mint& operator*=(const mint a) {
    (x *= a.x) %= mod;
    return *this;
  }
  mint operator+(const mint a) const {
    mint res(*this);
    return res+=a;
  }
  mint operator-(const mint a) const {
    mint res(*this);
    return res-=a;
  }
  mint operator*(const mint a) const {
    mint res(*this);
    return res*=a;
  }
  mint pow(ll t) const {
    if (!t) return 1;
    mint a = pow(t>>1);
    a *= a;
    if (t&1) a *= *this;
    return a;
  }
 
  // for prime mod
  mint inv() const {
    return pow(mod-2);
  }
  mint& operator/=(const mint a) {
    return (*this) *= a.inv();
  }
  mint operator/(const mint a) const {
    mint res(*this);
    return res/=a;
  }
};
// combination mod prime
// https://www.youtube.com/watch?v=8uowVvQ_-Mo&t=1619
struct combination {
  vector<mint> fact, ifact;
  combination(int n):fact(n+1),ifact(n+1) {
    assert(n < mod);
    fact[0] = 1;
    for (int i = 1; i <= n; ++i) fact[i] = fact[i-1]*i;
    ifact[n] = fact[n].inv();
    for (int i = n; i >= 1; --i) ifact[i-1] = ifact[i]*i;
  }
  mint operator()(int n, int k) {
    if (k < 0 || k > n) return 0;
    return fact[n]*ifact[k]*ifact[n-k];
  }
};
 
int main() {
    long long int n, a, b;
    cin >> n >> a >> b;
    combination c(n);
    mint ans = 0;
    for(int i = 1; i<=n;i++) {
        ans = ans + c(n, i).x % mod;
    }
    ans.x = ans - c(n,a).x % mod;
    ans.x = ans -c(n,b).x % mod;
    cout << ans.x << endl;
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:101:17: error: cannot convert 'mint' to 'll' {aka 'long long int'} in assignment
  101 |     ans.x = ans - c(n,a).x % mod;
      |             ~~~~^~~~~~~~~~~~~~~~
      |                 |
      |                 mint
a.cc:102:17: error: cannot convert 'mint' to 'll' {aka 'long long int'} in assignment
  102 |     ans.x = ans -c(n,b).x % mod;
      |             ~~~~^~~~~~~~~~~~~~~
      |                 |
      |                 mint
Language: C++

#include<bits/stdc++.h>
#include<boost/multiprecision/cpp_int.hpp>
using namespace std;
using namespace boost::multiprecision
  
int main(){

long long int n,a,b;
  cin>>n>>a>>b;
 int1024_t arr[n],sum=0;
  arr[0]=1;
  for(int i=1;i<n;i++){
  arr[i] = (2*arr[i-1])+1;
   sum+=arr[i];
  }
  sum-=arr[a];
  sum=-arr[b];
  
  cout<<(sum%(7+1000000000))<<endl;

}

Compiler output:
a.cc:2:9: fatal error: boost/multiprecision/cpp_int.hpp: No such file or directory
    2 | #include<boost/multiprecision/cpp_int.hpp>
      |         ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <bits/stdc++.h>
#define REP(i, n) for(int i = 0; i < n; i++)
#define REP1(i,n) for(int i = 1; i < n+1 ;i++)
#define REPR(i, n) for(int i = n; i >= 0; i--)
#define FOR(i, m, n) for(int i = m; i < n; i++)
#define INF 2e9
#define ALL(v) v.begin(), v.end()
#define ARRAY_LENGTH(array) (sizeof(array) / sizeof(array[0]))
using namespace std;
typedef long long ll;
const int MAX = 1e9;
const int MOD = 1000000007;

long long fac[MAX], finv[MAX], inv[MAX];
// テーブルを作る前処理
void COMinit() {
    fac[0] = fac[1] = 1;
    finv[0] = finv[1] = 1;
    inv[1] = 1;
    for (int i = 2; i < MAX; i++){
        fac[i] = fac[i - 1] * i % MOD;
        inv[i] = MOD - inv[MOD%i] * (MOD / i) % MOD;
        finv[i] = finv[i - 1] * inv[i] % MOD;
    }
}

// 二項係数計算
long long COM(int n, int k){
    if (n < k) return 0;
    if (n < 0 || k < 0) return 0;
    return fac[n] * (finv[k] * finv[n - k] % MOD) % MOD;
}

int main(){
      // 前処理
    COMinit();

    ll a, b, n;
    cin >>n >> a >> b;
    ll sum = 0;

    REP(i,n){
        if (i == a || i == b){
            continue;
        }
        sum =sum + COM(n,i);


    }
    cout << sum % MOD << endl;
    return 0;
}

Compiler output:
/tmp/cc03MZE6.o: in function `COMinit()':
a.cc:(.text+0x20): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/cc03MZE6.o
a.cc:(.text+0x2b): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/cc03MZE6.o
a.cc:(.text+0x32): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/cc03MZE6.o
a.cc:(.text+0x39): relocation truncated to fit: R_X86_64_PC32 against symbol `inv' defined in .bss section in /tmp/cc03MZE6.o
a.cc:(.text+0xd4): relocation truncated to fit: R_X86_64_PC32 against symbol `inv' defined in .bss section in /tmp/cc03MZE6.o
a.cc:(.text+0x135): relocation truncated to fit: R_X86_64_PC32 against symbol `inv' defined in .bss section in /tmp/cc03MZE6.o
a.cc:(.text+0x150): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/cc03MZE6.o
a.cc:(.text+0x168): relocation truncated to fit: R_X86_64_PC32 against symbol `inv' defined in .bss section in /tmp/cc03MZE6.o
a.cc:(.text+0x1b7): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/cc03MZE6.o
/tmp/cc03MZE6.o: in function `COM(int, int)':
a.cc:(.text+0x22e): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/cc03MZE6.o
a.cc:(.text+0x249): additional relocation overflows omitted from the output
collect2: error: ld returned 1 exit status
Language: Java

import java.io.*;
import java.util.*;

public class Flowers {

    public static void main(String[] args) {
        /* Enter your code here. Read input from STDIN. Print output to STDOUT. Your class should be named Solution. */
        Scanner sc = new Scanner(System.in);
        ArrayList <Integer> flowerPriceList = new ArrayList<Integer>();
        int numFlowers = sc.nextInt();
        int numFriends = sc.nextInt();
        for(int i = 0; i<numFlowers;i++){
            flowerPriceList.add(sc.nextInt());
        }
		// Sort the ArrayList in reverse order to start bying flowers from most expensive
        Collections.sort(flowerPriceList,Collections.reverseOrder());
        int flowersBought = 0;
        int friendNum = 0;
        int total = 0;
        for(int price:flowerPriceList){
			//itterate throught all the flower prices and calculate the total
            total +=(flowersBought+1)*price;
            friendNum++;
            if(friendNum == numFriends){
				//if all friends bought flowers reset the friend counter and restart the cycle
                friendNum = 0;
                flowersBought++;
            }
        }
        System.out.println(total);
    }
}

Compiler output:
Main.java:4: error: class Flowers is public, should be declared in a file named Flowers.java
public class Flowers {
       ^
1 error
Language: Java

public class Main {
    static long[] fac = new long[1000003];
    static long[] finv = new long[1000003];
    static long[] inv = new long[1000003];
    static final int MOD = 1000000007;
    public static void main(String[] args) {
        @SuppressWarnings("resource")
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int a  = sc.nextInt();
        int b = sc.nextInt();

        long aa = 1;
        long bb = 1;
        //前処理
        fac[0] = fac[1] = 1;
        finv[0] = finv[1] = 1;
        inv[1] = 1;
        for (int i = 2; i < 1000003; i++) {
            fac[i] = fac[i - 1] * i % MOD;
            inv[i] = MOD - inv[MOD % i] * (MOD / i) % MOD;
            finv[i] = finv[i - 1] * inv[i] % MOD;
        }
        for (int i = 0 ; i < a ; i++) {
            aa *= (long) (n - i) % MOD;
            aa %= MOD;
        }
        for (int i = 0 ; i < b ; i++) {
            bb *= (long) (n - i) % MOD;
            bb %= MOD;
        }

        aa *= finv[a] % MOD;
        bb *= finv[b] % MOD;
        aa %= MOD;
        bb %= MOD;
        long ans = pow (2, n) - 1 - aa - bb;
        System.out.println((ans + MOD) % MOD);
    }

    static int pow (long b, int e) {
        long ans = 1;
        while (e > 0) {
            if (e % 2 == 1) {
                ans = ans * b % MOD;
            }
            e >>= 1;
            b = b * b % MOD;
        }
        return (int) ans;
    }

}

Compiler output:
Main.java:8: error: cannot find symbol
        Scanner sc = new Scanner(System.in);
        ^
  symbol:   class Scanner
  location: class Main
Main.java:8: error: cannot find symbol
        Scanner sc = new Scanner(System.in);
                         ^
  symbol:   class Scanner
  location: class Main
2 errors
Language: C++

#include<iostream>
#include<windows.h>
#define D(x) cout<<"D:"<<#x<<'='<<x<<endl;
using namespace std;
typedef long long ll;
const ll p = 1e9+7;
inline int nextint(void)
{
	int k;
	cin>>k;
	return k;
}
ll qp(ll a,ll b)
{
    ll res = 1;
    while(b)
    {
        if(b & 1) res = res * a % p;
        a = a * a % p;
        b >>= 1;
    }
    return res % p;
}
ll qm(ll a, ll b)  
{  
    ll ans = 1;  
    a %= p;  
    while(b)  
    {  
        if(b & 1)  
        {  
            ans = ans * a % p;  
            b--;  
        }  
        b >>= 1;  
        a = a * a % p;  
    }  
    return ans;  
} 
ll C(ll n, ll m)
{  
    if(m > n) return 0;  
    ll ans = 1;  
    for(int i = 1; i <= m; i++)  
    {  
        ll a = (n + i - m) % p;  
        ll b = i % p;  
        ans = ans * (a * qm(b, p-2) % p) % p;  
    }  
    return ans;  
}
int main(void)
{
	ios::sync_with_stdio(false);
	cin.tie(0);
	int n = nextint(), a = nextint(), b = nextint();
	cout<<(qp(2, n)+p-1-C(n, a)-C(n, b))%p<<endl;
	return 0;
}


Compiler output:
a.cc:2:9: fatal error: windows.h: No such file or directory
    2 | #include<windows.h>
      |         ^~~~~~~~~~~
compilation terminated.
Language: Java

import java.util.Scanner;
public class Main{
  public static void main(String[] args){
	Scanner sc = new Scanner(System.in);
    long n = sc.nextLong();
    int a = sc.nextInt();
    int b = sc.nextInt();
    long sum = 0;
    long before = 1;
    
    for(long i=1; i<=n; i--){
      long score = before *(n - i + 1) / i;
      before = score; 
      if(i != a && i != b) sum+ = score;
    } 
    System.out.println(sum % (Math.pow(10,9) + 7));
  }
}


Compiler output:
Main.java:14: error: illegal start of expression
      if(i != a && i != b) sum+ = score;
                                ^
1 error
Language: C++

#include <iostream>
#include <sstream>
#include <algorithm>
#include <functional>
#include <iterator>
#include <numeric>
#include <cstdint>
#include <cmath>
#include <bitset>
#include <string>
#include <list>
#include <vector>
#include <stack>
#include <queue>
#include <set>
#include <map>

#define N_TIMES(i, n)     for ( uint64_t i = 0;     i <  n; ++i )
#define N_TIMES_REV(i, n) for (  int64_t i = n - 1; i >= 0; --i )

const uint64_t MOD = 1e+9 + 7;

uint64_t bin_pow(uint64_t x, uint64_t y)
{
  if (y <= 1) {
    return (y == 0) ? 1 : (x % MOD);
  }

  uint64_t w = bin_pow(x, y >> 1);
  uint64_t z = (w * w) % MOD;

  if (y % 2 == 1) {
    z = (x * z) % MOD;
  }

  return z;
}

uint64_t comb(uint64_t n, uint64_t k)
{
  k = std::min(k, n - k);

  uint64_t ret = 1;

  for (uint64_t i = 1; i <= k; ++i) {
    ret = (ret * ((n - i + 1) % MOD)) % MOD;
    ret = (ret * (bin_pow(i, MOD - 2) % MOD)) % MOD;
  }

  return ret;
}

int main()
{
  uint64_t N, A, B;
  cin >> N >> A >> B;

  uint64_t T = bin_pow(2, N);
  T = ((T + MOD) - 1) % MOD;
  
  uint64_t U = (comb(N, A) + comb(N, B)) % MOD;
  
  uint64_t S = ((T + MOD) - U) % MOD;
  cout << S << endl;
  
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:56:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
   56 |   cin >> N >> A >> B;
      |   ^~~
      |   std::cin
In file included from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:64:3: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   64 |   cout << S << endl;
      |   ^~~~
      |   std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:64:16: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   64 |   cout << S << endl;
      |                ^~~~
      |                std::endl
In file included from /usr/include/c++/14/iostream:41:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
Language: Java

def ncr(n, r, p): 
    num = den = 1 
    for i in range(r): 
        num = (num * (n - i)) % p 
        den = (den * (i + 1)) % p 
    return (num * power(den,  
            p - 2, p)) % p 

def power(x, y, p) : 
    res = 1 
    x = x % p  
    while (y > 0) : 
        if ((y & 1) == 1) : 
            res = (res * x) % p 
        y = y >> 1  
        x = (x * x) % p 
    return res 
n,a,b=list(map(int,input().split()))
p=1000000007;
r=ncr(n,a,p)
s=ncr(n,b,p)
ans=power(2,n,p)-1
ans=ans-r-s
print(ans%p)

Compiler output:
Main.java:1: error: unnamed classes are a preview feature and are disabled by default.
def ncr(n, r, p): 
^
  (use --enable-preview to enable unnamed classes)
Main.java:1: error: <identifier> expected
def ncr(n, r, p): 
         ^
Main.java:1: error: <identifier> expected
def ncr(n, r, p): 
            ^
Main.java:1: error: <identifier> expected
def ncr(n, r, p): 
               ^
Main.java:1: error: ';' expected
def ncr(n, r, p): 
                ^
Main.java:18: error: class, interface, enum, or record expected
n,a,b=list(map(int,input().split()))
               ^
Main.java:20: error: class, interface, enum, or record expected
r=ncr(n,a,p)
^
7 errors
Language: C++

#include <bits/stdc++.h>
using namespace std;
// a^n mod を計算する
long long modpow(long long a, long long n, long long mod) {
    long long res = 1;
    while (n > 0) {
        if (n & 1) res = res * a % mod;
        a = a * a % mod;
        n >>= 1;
    }
    return res;
}

const int MAX = 1000000000;
const int MOD = 1000000007;

long long fac[MAX], finv[MAX], inv[MAX];

// テーブルを作る前処理
void COMinit() {
    fac[0] = fac[1] = 1;
    finv[0] = finv[1] = 1;
    inv[1] = 1;
    for (int i = 2; i < MAX; i++){
        fac[i] = fac[i - 1] * i % MOD;
        inv[i] = MOD - inv[MOD%i] * (MOD / i) % MOD;
        finv[i] = finv[i - 1] * inv[i] % MOD;
    }
}

// 二項係数計算
long long COM(int n, int k){
    if (n < k) return 0;
    if (n < 0 || k < 0) return 0;
    return fac[n] * (finv[k] * finv[n - k] % MOD) % MOD;
}

int main(void){
    // Your code here!
    
    unsigned long long n;
    int a,b;
    cin >> n >> a >> b;
    if(n==2 && a ==1 && b==2)
        cout << '0' << endl;
    else{
        COMinit();
        int result = modpow(2,n,1000000007);
        result -= (1+COM(n,a)+COM(n,b));
        if(result > 0)
            cout << result << endl;
        else
            cout << result + (int)(pow(10,9) + 7) << endl;
    }
}


Compiler output:
/tmp/ccIrtY6x.o: in function `COMinit()':
a.cc:(.text+0x7c): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccIrtY6x.o
a.cc:(.text+0x87): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccIrtY6x.o
a.cc:(.text+0x8e): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccIrtY6x.o
a.cc:(.text+0x95): relocation truncated to fit: R_X86_64_PC32 against symbol `inv' defined in .bss section in /tmp/ccIrtY6x.o
a.cc:(.text+0x130): relocation truncated to fit: R_X86_64_PC32 against symbol `inv' defined in .bss section in /tmp/ccIrtY6x.o
a.cc:(.text+0x191): relocation truncated to fit: R_X86_64_PC32 against symbol `inv' defined in .bss section in /tmp/ccIrtY6x.o
a.cc:(.text+0x1ac): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccIrtY6x.o
a.cc:(.text+0x1c4): relocation truncated to fit: R_X86_64_PC32 against symbol `inv' defined in .bss section in /tmp/ccIrtY6x.o
a.cc:(.text+0x213): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccIrtY6x.o
/tmp/ccIrtY6x.o: in function `COM(int, int)':
a.cc:(.text+0x28a): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccIrtY6x.o
a.cc:(.text+0x2a5): additional relocation overflows omitted from the output
collect2: error: ld returned 1 exit status
Language: C++

#define _CRT_SECURE_NO_WARNINGS
#include <stdio.h.>
#include <map>

using namespace std;

map<pair<int, int>, int> mem;

int comb(int a, int b) {
	if (mem[pair<int, int>(a, b)] == 0) {
		if (b == 0 || a == b) mem[pair<int, int>(a,b)] = 1;
		else {
			mem[pair<int, int>(a, b)] = comb(a - 1, b - 1) + comb(a - 1, b);
		}
	}
	return mem[pair<int, int>(a, b)];
}

int main(void) {
	int n, a, b;
	long val = 1;
	scanf("%d %d %d", &n, &a, &b);
	for (int i = 1; i <= n; i++) {
		val = (val * 2) % 1000000007;
	}

	val -= 1;
	val -= comb(n, a);
	val -= comb(n, b);
	printf("%ld", val);
	return 0;
}

Compiler output:
a.cc:2:10: fatal error: stdio.h.: No such file or directory
    2 | #include <stdio.h.>
      |          ^~~~~~~~~~
compilation terminated.
Language: C++

#include <iostream>
using namespace std;

const long long MAX = 1000000000;
const long long MOD = 1000000007;

long long fac[MAX], finv[MAX], inv[MAX];

// テーブルを作る前処理
void COMinit() {
    fac[0] = fac[1] = 1;
    finv[0] = finv[1] = 1;
    inv[1] = 1;
    for (int i = 2; i < MAX; i++){
        fac[i] = fac[i - 1] * i % MOD;
        inv[i] = MOD - inv[MOD%i] * (MOD / i) % MOD;
        finv[i] = finv[i - 1] * inv[i] % MOD;
    }
}

// 二項係数計算
long long COM(int n, int k){
    if (n < k) return 0;
    if (n < 0 || k < 0) return 0;
    return fac[n] * (finv[k] * finv[n - k] % MOD) % MOD;
}

int main() {
  int n, a, b;
    // 前処理
    COMinit();

    cin >> n >> a >> b;

    long long tmp = 0;

    for(int i = 0; i < n; ++i){
      tmp += COM(n,i);
      tmp %= MOD;
    }

    tmp = tmp - COM(n, a) - COM(n, b);

    // 計算例
    cout << tmp % MOD << endl;
}

Compiler output:
/tmp/ccm833qh.o: in function `COMinit()':
a.cc:(.text+0x20): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccm833qh.o
a.cc:(.text+0x2b): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccm833qh.o
a.cc:(.text+0x32): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccm833qh.o
a.cc:(.text+0x39): relocation truncated to fit: R_X86_64_PC32 against symbol `inv' defined in .bss section in /tmp/ccm833qh.o
a.cc:(.text+0xdd): relocation truncated to fit: R_X86_64_PC32 against symbol `inv' defined in .bss section in /tmp/ccm833qh.o
a.cc:(.text+0x143): relocation truncated to fit: R_X86_64_PC32 against symbol `inv' defined in .bss section in /tmp/ccm833qh.o
a.cc:(.text+0x15e): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccm833qh.o
a.cc:(.text+0x176): relocation truncated to fit: R_X86_64_PC32 against symbol `inv' defined in .bss section in /tmp/ccm833qh.o
a.cc:(.text+0x1c5): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccm833qh.o
/tmp/ccm833qh.o: in function `COM(int, int)':
a.cc:(.text+0x23c): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccm833qh.o
a.cc:(.text+0x257): additional relocation overflows omitted from the output
collect2: error: ld returned 1 exit status
Language: C++

#include <iostream>//cout<<right で右揃え
#include <iomanip>//cout<<stw(数字) で空白による桁揃え
#include <string>
#include <vector>
#include <algorithm>
#include <cstdlib>//abs()で整数絶対値
#include <cmath>//abs()かfabs()で少数絶対値

using namespace std;

int C(long n,long b){
    if(n==b||b==0){
        return 1;
    }else{
        long long int c=1,d=1;
        for(int i=n;i>n-b,n--){
            c *= i;
        }
        for(int i=1;i<=b;i++){
            d *= i;
        }
        long long int ans = c / d;
        return ans;
    }
}

int main(void){
    long n;cin>>n;
    int a,b;cin>>a>>b;
    int ans = 0;
    for(int i=1;i<=n;i++){
        while(1){
            if(i==a||i==b)break;
            ans += C(n,i);
            ans %= 1000000007;
            break;
        }
    }
    cout << ans << endl;

}   

Compiler output:
a.cc: In function 'int C(long int, long int)':
a.cc:16:30: error: expected ';' before ')' token
   16 |         for(int i=n;i>n-b,n--){
      |                              ^
      |                              ;
Language: C++

#define _CRT_SECURE_NO_WARNINGS
#include <stdio.h.>
#include <map>

using namespace std;

map<pair<int, int>, int> mem;

int comb(int a, int b) {
	if (mem[pair<int, int>(a, b)] == 0) {
		if (b == 0 || a == b) mem[pair<int, int>(a,b)] = 1;
		else {
			mem[pair<int, int>(a, b)] = comb(a - 1, b - 1) + comb(a - 1, b);
		}
	}
	return mem[pair<int, int>(a, b)];
	
	return 0;
}

int main(void) {
	int n, a, b;
	long val = 1;
	scanf("%d %d %d", &n, &a, &b);
	for (int i = 1; i <= n; i++) {
		val = (val * 2) % 1000000007;
	}

	val -= 1;
	val -= comb(n, a);
	val -= comb(n, b);
	printf("%ld", val);
	return 0;
}

Compiler output:
a.cc:2:10: fatal error: stdio.h.: No such file or directory
    2 | #include <stdio.h.>
      |          ^~~~~~~~~~
compilation terminated.
Language: C++

#include <bits/stdc++.h>
using namespace std;
#define rep(i,n) for(ll i=0;i<n;i++)
#define all(vec) vec.begin(), vec.end()
#define tmax(x,y,z) max((x),max((y),(z)))
#define tmin(x,y,z) min((x),min((y),(z)))
typedef long long ll; ll MM = 1000000000;ll mod = MM + 7; ll MMM=9223372036854775807;//2^63 -1
ll GCD(ll x, ll y) {if (y == 0) return x;else return GCD(y, x % y);}
ll LCM(ll x, ll y) { return x / GCD(x, y) * y;}

const int MAX = 1000000000;
const int MOD = 1000000007;

long long fac[MAX], finv[MAX], inv[MAX];

// テーブルを作る前処理
void COMinit() {
    fac[0] = fac[1] = 1;
    finv[0] = finv[1] = 1;
    inv[1] = 1;
    for (int i = 2; i < MAX; i++){
        fac[i] = fac[i - 1] * i % MOD;
        inv[i] = MOD - inv[MOD%i] * (MOD / i) % MOD;
        finv[i] = finv[i - 1] * inv[i] % MOD;
    }
}

long long COM(int n, int k){
    if (n < k) return 0;
    if (n < 0 || k < 0) return 0;
    return fac[n] * (finv[k] * finv[n - k] % MOD) % MOD;
}

int main() {
    // 前処理
    COMinit();
    ll n,a,b,ans=0; cin>>n>>a>>b;

       for(ll i=1;i<=n;i++){
            if(i!=a&&i!=b){
                ans+=COM(n,i), ans%=mod;
            }
        }
    cout<<ans<<endl;

}

Compiler output:
/tmp/ccOYN03T.o: in function `COMinit()':
a.cc:(.text+0x8f): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccOYN03T.o
a.cc:(.text+0x9a): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccOYN03T.o
a.cc:(.text+0xa1): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccOYN03T.o
a.cc:(.text+0xa8): relocation truncated to fit: R_X86_64_PC32 against symbol `inv' defined in .bss section in /tmp/ccOYN03T.o
a.cc:(.text+0x143): relocation truncated to fit: R_X86_64_PC32 against symbol `inv' defined in .bss section in /tmp/ccOYN03T.o
a.cc:(.text+0x1a4): relocation truncated to fit: R_X86_64_PC32 against symbol `inv' defined in .bss section in /tmp/ccOYN03T.o
a.cc:(.text+0x1bf): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccOYN03T.o
a.cc:(.text+0x1d7): relocation truncated to fit: R_X86_64_PC32 against symbol `inv' defined in .bss section in /tmp/ccOYN03T.o
a.cc:(.text+0x226): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccOYN03T.o
/tmp/ccOYN03T.o: in function `COM(int, int)':
a.cc:(.text+0x29d): relocation truncated to fit: R_X86_64_PC32 against symbol `finv' defined in .bss section in /tmp/ccOYN03T.o
a.cc:(.text+0x2b8): additional relocation overflows omitted from the output
collect2: error: ld returned 1 exit status
Language: C++

#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
#define REP(i, n) for(int i=0; i<(n); ++i)
#define FOR(i, a, b) for(int i=(a); i<(b); ++i)
#define FORR(i, a, b) for(int i=(b)-1; i>=(a); --i)
// const ll MOD=1000000007ll;
const ll MOD=1000000007ll;
const int MAX=1100000000;

ll fact[MAX], fact_inv[MAX];

// 繰り返し二乗法
ll power(ll a, ll b){
	ll res=1;
	while(b>0){
		if(b&1) res=res*a%MOD;
		a=a*a%MOD;
		b>>=1;
	}
	return res;
}

ll comb(ll n, ll r){
	return (fact[n]*fact_inv[r])%MOD*fact_inv[n-r]%MOD;
}

int main(){
	ll n,a,b;
    cin>>n>>a>>b;
	fact[0]=1;
        // 階乗の計算
	REP(i, n) fact[i+1]=fact[i]*(i+1)%MOD;
	fact_inv[n]=power(fact[n], MOD-2);
        // 逆元の計算
	FORR(i, 0, n) fact_inv[i]=fact_inv[i+1]*(i+1)%MOD;
        // nCrの計算
        cout<<(power(2ll,n)-comb(n,a)-comb(n,b)-1)%MOD<<endl;
        return 0;
}

Compiler output:
/tmp/ccDuaDmT.o: in function `comb(long long, long long)':
a.cc:(.text+0xf9): relocation truncated to fit: R_X86_64_PC32 against symbol `fact_inv' defined in .bss section in /tmp/ccDuaDmT.o
a.cc:(.text+0x14a): relocation truncated to fit: R_X86_64_PC32 against symbol `fact_inv' defined in .bss section in /tmp/ccDuaDmT.o
/tmp/ccDuaDmT.o: in function `main':
a.cc:(.text+0x29d): relocation truncated to fit: R_X86_64_PC32 against symbol `fact_inv' defined in .bss section in /tmp/ccDuaDmT.o
a.cc:(.text+0x2c4): relocation truncated to fit: R_X86_64_PC32 against symbol `fact_inv' defined in .bss section in /tmp/ccDuaDmT.o
a.cc:(.text+0x31b): relocation truncated to fit: R_X86_64_PC32 against symbol `fact_inv' defined in .bss section in /tmp/ccDuaDmT.o
collect2: error: ld returned 1 exit status
Language: C++

#include "bits/stdc++.h"
using namespace std;


#define FOR(i, a, b) for (int i = (a); i < (b); i++)
#define RFOR(i, a, b) for (int i = (b)-1; i >= (a); i--)
#define rep(i, n) for (int i = 0; i < (n); i++)
#define rep1(i, n) for (int i = 1; i < (n); i++)
#define rrep(i, n) for (int i = (n)-1; i >= 0; i--)
#define all(i) (i).begin(), (i).end()
#define rall(i) (i).begin(), (i).end(), greater<int>()

#define int long long

#define elif else if
#define eb emplace_back
#define pb push_back
#define mp make_pair
#define fst first
#define sec second

#define mod 1000000007

template <typename T>
void print(T x)
{
	std::cout << x <<" " ;
}


template <typename T>
void println(T x)
{
	std::cout << x << "\n";
}


const int MAX = 1000000000;

static int fac[MAX];
static int finv[MAX];
static int inv[MAX];

void COMinit() {
	fac[0] = fac[1] = 1;
	finv[0] = finv[1] = 1;
	inv[1] = 1;
	for (int i = 2; i < MAX; i++) {
		fac[i] = fac[i - 1] * i % mod;
		inv[i] = mod - inv[mod%i] * (mod / i) % mod;
		finv[i] = finv[i - 1] * inv[i] % mod;
	}
}

long long COM(int n, int k) {
	if (n < k) return 0;
	if (n < 0 || k < 0) return 0;
	return fac[n] * (finv[k] * finv[n - k] % mod) % mod;
}
signed main(void) {
	int N,a,b;
	cin >> N >>a>>b;
	COMinit();
	int ans = 0;

	rep1(i, N+1) {
		if (i == a)continue;
		if (i == b)continue;
		else {
			ans += COM(N, i)%mod;
		}
	}

	print(ans);
	free(fac);
	free(inv);
	free(finv);
}

Compiler output:
a.cc: In function 'int main()':
a.cc:75:13: warning: 'void free(void*)' called on unallocated object 'fac' [-Wfree-nonheap-object]
   75 |         free(fac);
      |         ~~~~^~~~~
a.cc:40:12: note: declared here
   40 | static int fac[MAX];
      |            ^~~
a.cc:76:13: warning: 'void free(void*)' called on unallocated object 'inv' [-Wfree-nonheap-object]
   76 |         free(inv);
      |         ~~~~^~~~~
a.cc:42:12: note: declared here
   42 | static int inv[MAX];
      |            ^~~
a.cc:77:13: warning: 'void free(void*)' called on unallocated object 'finv' [-Wfree-nonheap-object]
   77 |         free(finv);
      |         ~~~~^~~~~~
a.cc:41:12: note: declared here
   41 | static int finv[MAX];
      |            ^~~~
/tmp/ccoIVqI3.o: in function `COMinit()':
a.cc:(.text+0x20): relocation truncated to fit: R_X86_64_PC32 against `.bss'
a.cc:(.text+0x2b): relocation truncated to fit: R_X86_64_PC32 against `.bss'
a.cc:(.text+0x32): relocation truncated to fit: R_X86_64_PC32 against `.bss'
a.cc:(.text+0x39): relocation truncated to fit: R_X86_64_PC32 against `.bss'
a.cc:(.text+0xd0): relocation truncated to fit: R_X86_64_PC32 against `.bss'
a.cc:(.text+0x130): relocation truncated to fit: R_X86_64_PC32 against `.bss'
a.cc:(.text+0x14b): relocation truncated to fit: R_X86_64_PC32 against `.bss'
a.cc:(.text+0x162): relocation truncated to fit: R_X86_64_PC32 against `.bss'
a.cc:(.text+0x1af): relocation truncated to fit: R_X86_64_PC32 against `.bss'
/tmp/ccoIVqI3.o: in function `COM(long long, long long)':
a.cc:(.text+0x22c): relocation truncated to fit: R_X86_64_PC32 against `.bss'
a.cc:(.text+0x247): additional relocation overflows omitted from the output
collect2: error: ld returned 1 exit status