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

#include <bits/stdc++.h>
using namespace std;
main(){
  int n,k,d[10]={},tmp;
  vector <int> dl;
  for(cin>>n>>k;;cin>>tmp;dl.push_back(tmp));
  for(;;n++){
    for(int a=n;a;a/=10) for(int i=0;i<dl.size();i++) if(dl[i]==a%10) goto end;
    cout<<n<<endl;
    return 0;
  end:;
  }
}

Compiler output:
a.cc:3:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    3 | main(){
      | ^~~~
a.cc: In function 'int main()':
a.cc:6:26: error: expected ')' before ';' token
    6 |   for(cin>>n>>k;;cin>>tmp;dl.push_back(tmp));
      |      ~                   ^
      |                          )
a.cc:6:44: error: expected ';' before ')' token
    6 |   for(cin>>n>>k;;cin>>tmp;dl.push_back(tmp));
      |                                            ^
      |                                            ;
Language: C++

#include <bits/stdc++11.h>
using namespace std;
main(){
  int n,k,d[10]={},tmp;
  vector <int> dl;
  for(cin>>n>>k;;cin>>tmp;dl.push_back(tmp));
  for(;;n++){
    for(int a=n;a;a/=10) for(int i=0;i<dl.size();i++) if(dl[i]==a%10) goto end;
    cout<<n<<endl;
    return 0;
  end:;
  }
}

Compiler output:
a.cc:1:10: fatal error: bits/stdc++11.h: No such file or directory
    1 | #include <bits/stdc++11.h>
      |          ^~~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include <iostream>
using namespace std;
main(){
  int n,k,d[10]={},tmp;
  vector <int> dl;
  for(cin>>n>>k;;cin>>tmp;dl.push_back(tmp));
  for(;;n++){
    for(int a=n;a;a/=10) for(int i=0;i<dl.size();i++) if(dl[i]==a%10) goto end;
    cout<<n<<endl;
    return 0;
  end:;
  }
}

Compiler output:
a.cc:3:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    3 | main(){
      | ^~~~
a.cc: In function 'int main()':
a.cc:5:3: error: 'vector' was not declared in this scope
    5 |   vector <int> dl;
      |   ^~~~~~
a.cc:2:1: note: 'std::vector' is defined in header '<vector>'; this is probably fixable by adding '#include <vector>'
    1 | #include <iostream>
  +++ |+#include <vector>
    2 | using namespace std;
a.cc:5:11: error: expected primary-expression before 'int'
    5 |   vector <int> dl;
      |           ^~~
a.cc:6:26: error: expected ')' before ';' token
    6 |   for(cin>>n>>k;;cin>>tmp;dl.push_back(tmp));
      |      ~                   ^
      |                          )
a.cc:6:27: error: 'dl' was not declared in this scope; did you mean 'd'?
    6 |   for(cin>>n>>k;;cin>>tmp;dl.push_back(tmp));
      |                           ^~
      |                           d
Language: C++

#include<iostream>
#include<algorithm>
#include<vector>
std::vector<int> f;
bool fig[10];
int N, K;
int mods[5] = {10000,1000,100,10,1 };
int ans;
int main() {
	std::cin >> N >> K;
	for (int i = 0; i < K; i++) {
		int tmp;
		std::cin >> tmp;
		fig[tmp] = true;
	}
	for (int i = 0; i < 10; i++) {
		if (!fig[i]) {
			f.push_back(i);
		}
	}
	for (int i = 0; i < 5; i++) {
		int tmp = N/mods[i];
		if (tmp == 0)continue;
		N = N % mods[i];
		for (int j = 0; j <= f.size(); j++) {
			if (j == f.size()) {
				if (f[0] == 0)ans += f[1] * mods[i-1];
				else ans + =f[0] * mods[i-1];
				break;
			}
			if (tmp <= f[j]) {
				ans += mods[i] * f[j];
				break;
			}
		}
	}
	std::cout << ans << std::endl;
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:28:44: error: expected primary-expression before '=' token
   28 |                                 else ans + =f[0] * mods[i-1];
      |                                            ^
Language: C++

#include <assert.h>
#include <ctype.h>
#include <errno.h>
#include <float.h>
#include <fstream>
#include <iomanip>
#include <iostream>
#include <limits>
#include <locale>
#include <math.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include <wchar.h>
#include <wctype.h>
#include <algorithm>
#include <bitset>
#include <cctype>
#include <cerrno>
#include <clocale>
#include <cmath>
#include <complex>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <ctime>
#include <deque>
#include <exception>
#include <functional>
#include <map>
#include <ios>
#include <iosfwd>
#include <istream>
#include <ostream>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <stdexcept>
#include <streambuf>
#include <string>
#include <utility>
#include <vector>
#include <cwchar>
#include <cwctype>
#include <complex.h>
#include <fenv.h>
#include <inttypes.h>
#include <stdbool.h>
#include <stdint.h>
#include <tgmath.h>
#include <conio.h>
#include <numeric>
#include <list>
#include <windows.h>
#include <cfloat>
#include <climits>
#include <unordered_map>
#include <unordered_set>
using namespace std;

string n;
int k;
set<int> like,dlike;

int main()
{
	cin>>n>>k;
	for(int i=0;i<k;i++)
	{
		int a;
		cin>>a;
		dlike.insert(a);
	}
	for(int i=0;i<=10;i++) if(!dlike.count(i)) like.insert(i);
	
	for(int i=0;i<n.size();i++)
		if(dlike.count(n[i]-'0')) cout<<*like.upper_bound(n[i]-'0');
		else cout<<n[i];
	
	return 0;
}

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

#include <bits\stdc++.h>
using namespace std;
int n,m,i,j,a[15];
string st;
char s[15];
bool check(int x)
{
	sprintf(s,"%d",x);
	st=s;
	for (i=1;i<=m;i++)
	{
		if ((int)st.find(a[i]+'0')!=-1)
		{
			return 0;
		}
	}
	return 1;
}
int main()
{
	cin>>n>>m;
	for (i=1;i<=m;i++) cin>>a[i];
	while (!check(n)) 
		n++;
	cout<<n;
	return 0;
}
		

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

#include <iostream>
#include <cstdio>
#include <vector>
#define _USE_MATH_DEFINES
#include <math.h>
#include <cstring>
#include <numeric>
#include <algorithm>
#include <stdlib.h>
#include <functional>
#include <string>
#include <array>
#include <map>
#include <queue>
#include <limits.h>
#include <set>
#include <stack>
#include <random>
#include <complex>
#include <unordered_map>
#include <nmmintrin.h>
#include <chrono>
#define rep(i,s,n) for(int i = (s); (n) > i; i++)
#define REP(i,n) rep(i,0,n)
#define RANGE(x,a,b) ((a) <= (x) && (x) <= (b))
#define DUPLE(a,b,c,d) (RANGE(a,c,d) || RANGE(b,c,d) || RANGE(c,a,b) || RANGE(d,a,b))
#define INCLU(a,b,c,d) (RANGE(a,c,d) && (b,c,d))
#define PW(x) ((x)*(x))
#define ALL(x) (x).begin(), (x).end()
#define MODU 1000000007
#define bitcheck(a,b)   ((a >> b) & 1)
#define bitset(a,b)      ( a |= (1 << b))
#define bitunset(a,b)    (a &= ~(1 << b))
#define MP(a,b) make_pair((a),(b))
#define Manh(a,b) (abs((a).first-(b).first) + abs((a).second - ((b).second))
#define pritnf printf
#define scnaf scanf
#define itn int
#ifdef _MSC_VER
#define __builtin_popcount _mm_popcnt_u32
#define __builtin_popcountll _mm_popcnt_u64
#endif
using namespace std;
typedef long long ll;
typedef pair<int, int> pii;
typedef pair<ll, ll> pll;
ll gcd(ll a, ll b) {
	if (b == 0) return a;
	return gcd(b, a%b);
}
template<typename A, size_t N, typename T>
void Fill(A(&array)[N], const T &val) {
	std::fill((T*)array, (T*)(array + N), val);
}


signed main() {
	int n, k;
	scnaf("%d %d", &n, &k);
	int can[10] = {};
	REP(i, k) {
		int a;
		scnaf("%d", &a);
		can[a] = 1;
	}

	for (;; n++) {
		char str[10];
		itoa(n, str, 10);
		int len = strlen(str);
		bool f = 1;
		REP(i, len)
			if (can[str[i]-'0'])
				f = 0;
		if (f) {
			printf("%d\n", n);
			break;
		}
	}

	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:69:17: error: 'itoa' was not declared in this scope
   69 |                 itoa(n, str, 10);
      |                 ^~~~
Language: C++

#include <iostream>
#include <cstdio>
#include <vector>
#define _USE_MATH_DEFINES
#include <math.h>
#include <cstring>
#include <numeric>
#include <algorithm>
#include <stdlib.h>>
#include <functional>
#include <string>
#include <array>
#include <map>
#include <queue>
#include <limits.h>
#include <set>
#include <stack>
#include <random>
#include <complex>
#include <unordered_map>
#include <nmmintrin.h>
#include <chrono>
#define rep(i,s,n) for(int i = (s); (n) > i; i++)
#define REP(i,n) rep(i,0,n)
#define RANGE(x,a,b) ((a) <= (x) && (x) <= (b))
#define DUPLE(a,b,c,d) (RANGE(a,c,d) || RANGE(b,c,d) || RANGE(c,a,b) || RANGE(d,a,b))
#define INCLU(a,b,c,d) (RANGE(a,c,d) && (b,c,d))
#define PW(x) ((x)*(x))
#define ALL(x) (x).begin(), (x).end()
#define MODU 1000000007
#define bitcheck(a,b)   ((a >> b) & 1)
#define bitset(a,b)      ( a |= (1 << b))
#define bitunset(a,b)    (a &= ~(1 << b))
#define MP(a,b) make_pair((a),(b))
#define Manh(a,b) (abs((a).first-(b).first) + abs((a).second - ((b).second))
#define pritnf printf
#define scnaf scanf
#define itn int
#ifdef _MSC_VER
#define __builtin_popcount _mm_popcnt_u32
#define __builtin_popcountll _mm_popcnt_u64
#endif
using namespace std;
typedef long long ll;
typedef pair<int, int> pii;
typedef pair<ll, ll> pll;
ll gcd(ll a, ll b) {
	if (b == 0) return a;
	return gcd(b, a%b);
}
template<typename A, size_t N, typename T>
void Fill(A(&array)[N], const T &val) {
	std::fill((T*)array, (T*)(array + N), val);
}


signed main() {
	int n, k;
	scnaf("%d %d", &n, &k);
	int can[10] = {};
	REP(i, k) {
		int a;
		scnaf("%d", &a);
		can[a] = 1;
	}

	for (;; n++) {
		char str[10];
		itoa(n, str, 10);
		int len = strlen(str);
		bool f = 1;
		REP(i, len)
			if (can[str[i]-'0'])
				f = 0;
		if (f) {
			printf("%d\n", n);
			break;
		}
	}

	return 0;
}

Compiler output:
a.cc:9:20: warning: extra tokens at end of #include directive
    9 | #include <stdlib.h>>
      |                    ^
a.cc: In function 'int main()':
a.cc:69:17: error: 'itoa' was not declared in this scope
   69 |                 itoa(n, str, 10);
      |                 ^~~~
Language: C++

#include <iostream>
#include <cstdio>
#include <vector>
#define _USE_MATH_DEFINES
#include <math.h>
#include <cstring>
#include <numeric>
#include <algorithm>
#include <functional>
#include <string>
#include <array>
#include <map>
#include <queue>
#include <limits.h>
#include <set>
#include <stack>
#include <random>
#include <complex>
#include <unordered_map>
#include <nmmintrin.h>
#include <chrono>
#define rep(i,s,n) for(int i = (s); (n) > i; i++)
#define REP(i,n) rep(i,0,n)
#define RANGE(x,a,b) ((a) <= (x) && (x) <= (b))
#define DUPLE(a,b,c,d) (RANGE(a,c,d) || RANGE(b,c,d) || RANGE(c,a,b) || RANGE(d,a,b))
#define INCLU(a,b,c,d) (RANGE(a,c,d) && (b,c,d))
#define PW(x) ((x)*(x))
#define ALL(x) (x).begin(), (x).end()
#define MODU 1000000007
#define bitcheck(a,b)   ((a >> b) & 1)
#define bitset(a,b)      ( a |= (1 << b))
#define bitunset(a,b)    (a &= ~(1 << b))
#define MP(a,b) make_pair((a),(b))
#define Manh(a,b) (abs((a).first-(b).first) + abs((a).second - ((b).second))
#define pritnf printf
#define scnaf scanf
#define itn int
#ifdef _MSC_VER
#define __builtin_popcount _mm_popcnt_u32
#define __builtin_popcountll _mm_popcnt_u64
#endif
using namespace std;
typedef long long ll;
typedef pair<int, int> pii;
typedef pair<ll, ll> pll;
ll gcd(ll a, ll b) {
	if (b == 0) return a;
	return gcd(b, a%b);
}
template<typename A, size_t N, typename T>
void Fill(A(&array)[N], const T &val) {
	std::fill((T*)array, (T*)(array + N), val);
}


signed main() {
	int n, k;
	scnaf("%d %d", &n, &k);
	int can[10] = {};
	REP(i, k) {
		int a;
		scnaf("%d", &a);
		can[a] = 1;
	}

	for (;; n++) {
		char str[10];
		itoa(n, str, 10);
		int len = strlen(str);
		bool f = 1;
		REP(i, len)
			if (can[str[i]-'0'])
				f = 0;
		if (f) {
			printf("%d\n", n);
			break;
		}
	}

	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:68:17: error: 'itoa' was not declared in this scope
   68 |                 itoa(n, str, 10);
      |                 ^~~~
Language: C++

#include <cstdio>
#include <cstring>
#include <cstdlib>
#include <cmath>
#include <algorithm>
#include <vector>
#include <iostream>
#include <set>
#include <map>
using namespace std;
typedef long long ll;

int N, K;

int main(int argc, char const *argv[]) {
	cin >> N >> K;
	int a;
	vector<int> v;
	for (int i = 0; i < K; i++) {
		cin >> a;
		v.push_back(a)
	}

	string sx;
	for (int x = N; x < 10 * N; x++) {
		sx = to_string(x);
		bool flag = false;
		for (int i = 0; i < sx.size(); i++) {
			for (int j = 0; j < v.size(); j++)
				if (sx[i]-'0' == v[j]) flag = true;
		}
		if (!flag) {
			cout << x << endl;
			return 0;
		}
	}
	return 0;
}

Compiler output:
a.cc: In function 'int main(int, const char**)':
a.cc:21:31: error: expected ';' before '}' token
   21 |                 v.push_back(a)
      |                               ^
      |                               ;
   22 |         }
      |         ~
Language: Java

import java.util.Scanner;

public class　Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int n = sc.nextInt();
		int k = sc.nextInt();
		String kirai[] = new String[k];
		for (int i = 0; i < k; i++) {
			kirai[i] = sc.next();
		}

		String number[];
		number = String.valueOf(n).split("");
		String anser = "";
		String keta = "";
		for (int j = number.length - 1; j >= 0; j--) {
			for (int h = 0; h < kirai.length; h++) {
				if (kirai[h].equals(number[j])) {
					int n2 = (Integer.parseInt(number[j]) + 1) % 10;// これだと小さい数ができない
					// 大きい数字になったらケタ上がりしないといけない。
					number[j] = String.valueOf(n2);
					if (n2 == 0){
						h = 0;
						if(j == 0)keta = "1";
						else{
							int n3 = (Integer.parseInt(number[j-1])+1)%10;
							number[j-1] = String.valueOf(n3);
							for(int i = j-2;i >= 0;i--){
								if(number[i].equals("0")){
								n3 = Integer.parseInt(number[i])+1;
								number[i] = String.valueOf(n3);
								}
							}
						}
					}
				}
			}
		}

		for(int i = 0;i < number.length;i++){
			anser += number[i];
		}
		if(keta.equals("1")){
			keta += anser;
			System.out.println(keta);
		}else System.out.println(anser);
	}
}


Compiler output:
Main.java:3: error: illegal character: '\u3000'
public class?Main {
            ^
1 error
Language: Java

package xml1115;

import java.util.Scanner;

public class A {

	public static void main(String[] args) {
		Scanner scan = new Scanner(System.in);
		
		int n = scan.nextInt();
		int knum = scan.nextInt();
		int[] hateNums = new int[knum];
		for(int i = 0; i < knum; i++){
			hateNums[i] = scan.nextInt();
		}
		
		char[] likeNums = new char[10];
		int count = 0;
		for(int i=0; i<knum; i++){
			if(i != hateNums[i]){
				likeNums[count] = (char)i;
				count++;
			}
		}
		
//		count = 0;
//		int result = 0;
//		while(true){
//			for(int i=0; i<count; i++){
//				for(int t=0; t<likeNums.length; t++){
//					result = likeNums[t];
//					if(n < result){
//						System.out.println(result);
//						break;
//					}
//				}
//			}
//		}
		
		int result = n;
		String pu = "";
		for(int i=0; i<=10000; i++){
			
			String price = String.valueOf(n);
			String res = String.valueOf(result);
			
			int co = 0;
			for(int t=0; t<hateNums.length; t++){
				String s = String.valueOf(hateNums[t]);
				if(!res.contains(s)){
					co++;
				}
				if(co == hateNums.length){
					pu = res;
				}
			}
			if(pu != ""){
				break;
			}
			result++;
		}
		System.out.println(pu);
		
	}

}


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

import java.util.Scanner;

public class A {
    public static void main(String[] at){
        Scanner scanner = new Scanner(System.in);
        int mon = scanner.nextInt();
        String[] hate = new String [scanner.nextInt()];
        for (int i = 0; i < hate.length; i++){
            hate[i] = scanner.next();
        }
        String money = Integer.toString(mon);
        int result = mon;
        boolean ok = true;
        while (ok){
            for (int i = 0; i < hate.length; i++){
                if (money.matches(".*" + hate[i] + ".*")){
                    result++;
                    money = Integer.toString(result);
                    break;
                } else if (i == hate.length-1){
                    ok = false;
                }
            }
        }

        System.out.println(result);


    }
}


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

import java.util.Scanner;

public class　Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int n = sc.nextInt();
		int k = sc.nextInt();
		String kirai[] = new String[k];
		for (int i = 0; i < k; i++) {
			kirai[i] = sc.next();
		}

		String number[];
		number = String.valueOf(n).split("");
		String anser = "";
		for (int j = 0; j < number.length; j++) {
			for (int h = 0; h < kirai.length; h++) {// ここは二分探索のほうが良い
				if (kirai[h].equals(number[j])) {
					int n2 = (Integer.parseInt(number[j]) + 1) % 10;// これだと小さい数ができない
					number[j] = String.valueOf(n2);
					if(n2 == 1)h = 0;
				}
			}
			anser += number[j];
		}

		System.out.println(anser);
	}
}


Compiler output:
Main.java:3: error: illegal character: '\u3000'
public class?Main {
            ^
1 error
Language: C++

#include <cstdio>
#include <cstring>
#include <cmath>
#include <algorithm>
#include <sstream>
#include <iostream>
#include <vector>
#include <map>
#include <set>

using namespace std;

typedef unsigned long long ull;
typedef long long ll;
typedef vector<int> vi;
typedef vector<long> vl;

int
main()
{
    cin.tie(0);
    ios::sync_with_stdio(false);
    
    int n, k;
    cin >> n >> k;
    vi d;
    for (int i = 0; i < k; ++i) {
        int tmp;
        cin >> tmp;
        d.push_back(tmp);
    }

    for (int i = n; i < INT_MAX; ++i) {
        int num = i;
        bool invalid = false;
        while (num > 0) {
            int tmp = num % 10;
            for (int i = 0; i < k; ++i) {
                if (d[i] == tmp) {
                    invalid = true;
                }
            }
            if (invalid) break;
            num /= 10;
        }
        if (invalid) continue;

        cout << i << endl;
        return 0;
    }
    return 1;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:33:25: error: 'INT_MAX' was not declared in this scope
   33 |     for (int i = n; i < INT_MAX; ++i) {
      |                         ^~~~~~~
a.cc:10:1: note: 'INT_MAX' is defined in header '<climits>'; this is probably fixable by adding '#include <climits>'
    9 | #include <set>
  +++ |+#include <climits>
   10 |
Language: C++

#include<iostream>
using namespace std;
#include<vector>
int main()
{
    // get a integer
    int amt;
    int k;
    int bit_wise_d = 0;
    cin >> amt >> k; 
    for(int i = 0; i < k; i++){
        cin >> d;
        bit_wise_d |= 1 << d;
    }
    int ret = 0;
    while(amt > 0){
        ret *= 10;
        int min_d = amt%10;
        for(int i = min_d; i < 10; i++){
            if(bit_wise_d & (1 << i)){
                   ret += i;
            }
            else if(i == 9)
                 return -1;
        }
        ret += amt%10;
        amt /= 10;
    }
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:16: error: 'd' was not declared in this scope
   12 |         cin >> d;
      |                ^
Language: C++

/* template.cpp [[[ */
#include <bits/stdc++.h>
using namespace std;
#define get_macro(a, b, c, d, name, ...) name
#define rep(...) get_macro(__VA_ARGS__, rep4, rep3, rep2, rep1)(__VA_ARGS__)
#define rrep(...) get_macro(__VA_ARGS__, rrep4, rrep3, rrep2, rrep1)(__VA_ARGS__)
#define rep1(n) rep2(i_, n)
#define rep2(i, n) rep3(i, 0, n)
#define rep3(i, a, b) rep4(i, a, b, 1)
#define rep4(i, a, b, s) for (ll i = (a); i < (ll)(b); i += (ll)s)
#define rrep1(n) rrep2(i_, n)
#define rrep2(i, n) rrep3(i, 0, n)
#define rrep3(i, a, b) rrep4(i, a, b, 1)
#define rrep4(i, a, b, s) for (ll i = (ll)(b) - 1; i >= (ll)(a); i -= (ll)s)
#define each(x, c) for (auto &&x : c)
#define fs first
#define sc second
#define all(c) begin(c), end(c)
using ui = unsigned;
using ll = long long;
using ul = unsigned long long;
using ld = long double;
const int inf = 1e9 + 10;
const ll inf_ll = 1e18 + 10;
const ll mod = 1e9 + 7;
const ll mod9 = 1e9 + 9;
const int dx[]{-1, 0, 1, 0, -1, 1, 1, -1};
const int dy[]{0, -1, 0, 1, -1, -1, 1, 1};
template<class T, class U> void chmin(T &x, const U &y){ x = min<T>(x, y); }
template<class T, class U> void chmax(T &x, const U &y){ x = max<T>(x, y); }
struct prepare_ { prepare_(){ cin.tie(nullptr); ios::sync_with_stdio(false); cout << fixed << setprecision(12); } } prepare__;
ll in(){ ll x; cin >> x; return x; }
vector<ll> in(size_t n){ vector<ll> v(n); each(x, v) cin >> x; return v; }
/* ]]] */

int n, x, y, z;
ll dp[60][1 << 16];
ll pw10[60];

int dfs(int i, int j){
  int &res = dp[i][j];
  if (~res) return res;
  if (i == n) return res = 1;
  res = 0;
  rep(k, 1, 11){
    int nj = (j << k) | (1 << (k - 1));
    int f = 1;
    f &= (nj >> (z - 1)) & 1;
    f &= (nj >> (z + y - 1)) & 1;
    f &= (nj >> (z + y + x - 1)) & 1;
    if (f) continue;
    nj &= (1 << (x + y + z - 1)) - 1;
    res += dfs(i + 1, nj);
    res %= mod;
  }
  return res;
}

int main(){
  cin >> n >> x >> y >> z;
  pw10[0] = 1;
  rep(i, 59) pw10[i + 1] = pw10[i] * 10 % mod;
  memset(dp, -1, sizeof(dp));
  cout << (pw10[n] - dfs(0, 0) + mod) % mod << endl;
}


Compiler output:
a.cc: In function 'int dfs(int, int)':
a.cc:41:21: error: cannot bind non-const lvalue reference of type 'int&' to a value of type 'll' {aka 'long long int'}
   41 |   int &res = dp[i][j];
      |              ~~~~~~~^
Language: Java

/**
 * Created by iainws on 4/09/16.
 */

import java.io.InputStreamReader;
import java.io.IOException;
import java.io.BufferedReader;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.util.StringTokenizer;
import java.io.InputStream;

public class IrohasObsession {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReaderIrohasObsession in = new InputReaderIrohasObsession(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        TaskIrohasObsession solver = new TaskIrohasObsession();
        solver.solve(1, in, out);
        out.close();
    }
}

class TaskIrohasObsession {

    public boolean check(int cur, int [] arr){
        boolean ok = true;
        while(cur != 0){
            int r = cur % 10;
            for(int i = 0; i < arr.length; ++i){
                if(arr[i] == r)ok = false;
            }
            cur /= 10;
        }
        if(ok)return true;
        return false;
    }

    public void solve(int taskNumber, InputReaderIrohasObsession in, PrintWriter out) {
        int N;
        int K;
        N = in.nextInt();
        K = in.nextInt();
        int [] arr = new int[K];
        for(int i = 0; i < K; ++i){
            int a = in.nextInt();
            arr[i] = a;
        }
        for(int i = N; i < N * 10;++i){
            if(check(i, arr)){
                System.out.println(i);
                return;
            }
        }
    }
}

class InputReaderIrohasObsession {
    public BufferedReader reader;
    public StringTokenizer tokenizer;

    public InputReaderIrohasObsession(InputStream stream) {
        reader = new BufferedReader(new InputStreamReader(stream), 32768);
        tokenizer = null;
    }

    public String next() {
        while (tokenizer == null || !tokenizer.hasMoreTokens()) {
            try {
                tokenizer = new StringTokenizer(reader.readLine());
            } catch (IOException e) {
                throw new RuntimeException(e);
            }
        }
        return tokenizer.nextToken();
    }

    public int nextInt() {
        return Integer.parseInt(next());
    }

}

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

import java.util.*;


public class Main {
  int N, K;
  boolean[] D;
  int A;

  public static boolean isOK() {
    int a = A;
    while(A > 0) {
      if(D[a % 10]) return false;
      a = a / 10;
    }
    return true;
  }

  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);

    N = sc.nextInt();
    K = sc.nextInt();
    D = new int[10];
    for(int i = 0; i < K; i++) {
      int d = sc.nextInt();
      D[d] = true;
    }

    A = N;
    while(!isOK()) A++;

    System.out.println(A);
  }
}


Compiler output:
Main.java:10: error: non-static variable A cannot be referenced from a static context
    int a = A;
            ^
Main.java:11: error: non-static variable A cannot be referenced from a static context
    while(A > 0) {
          ^
Main.java:12: error: non-static variable D cannot be referenced from a static context
      if(D[a % 10]) return false;
         ^
Main.java:21: error: non-static variable N cannot be referenced from a static context
    N = sc.nextInt();
    ^
Main.java:22: error: non-static variable K cannot be referenced from a static context
    K = sc.nextInt();
    ^
Main.java:23: error: non-static variable D cannot be referenced from a static context
    D = new int[10];
    ^
Main.java:23: error: incompatible types: int[] cannot be converted to boolean[]
    D = new int[10];
        ^
Main.java:24: error: non-static variable K cannot be referenced from a static context
    for(int i = 0; i < K; i++) {
                       ^
Main.java:26: error: non-static variable D cannot be referenced from a static context
      D[d] = true;
      ^
Main.java:29: error: non-static variable A cannot be referenced from a static context
    A = N;
    ^
Main.java:29: error: non-static variable N cannot be referenced from a static context
    A = N;
        ^
Main.java:30: error: non-static variable A cannot be referenced from a static context
    while(!isOK()) A++;
                   ^
Main.java:32: error: non-static variable A cannot be referenced from a static context
    System.out.println(A);
                       ^
13 errors
Language: C++

#include<iostream>
#include<algorithm>
#include<utility>
#include<vector>
#include<queue>
#include<stack>
#include<map>
#include<set>
#include<string>
#include<stack>
#include<cstdio>
#include<cmath>
#include<iomanip>
using namespace std;
 
typedef long long ll;
typedef long double ld;
typedef pair<int,int> pii;
typedef pair<int,pii> piii;
typedef vector<int> vi;
typedef vector<pii> vpii;
 
#define fr first
#define sc second
#define mp make_pair
#define pb push_back
#define rep(i,x) for(int i=0;i<x;i++)
#define rep1(i,x) for(int i=1;i<=x;i++)
#define rrep(i,x) for(int i=x-1;i>=0;i--)
#define rrep1(i,x) for(int i=x;i>0;i--)
#define so(v) sort(v.begin(),v.end())
#define re(s) reverse(s.begin(),s.end())
#define lb(v,a) lower_bound(v.begin(),v.end(),a)
#define ub(v,a) upper_bound(v.begin(),v.end(),a)
#define mp1(a,b,c) piii(a,pii(b,c))
 
const int INF=1000000000;
const int dir_4[4][2]={{1,0},{0,1},{-1,0},{0,-1}};
const int dir_8[8][2]={{1,0},{1,1},{0,1},{-1,1},{-1,0},{-1,-1},{0,-1},{1,-1}};
const ll mod=1e9+7;

int main(){

  int n,k,d[20]={0};
  cin>>n>>k;
  rep(i,k){int a; cin>>a; d[a]=1;}
  for(;;){
    int t=n;
    while(t){
      if(f[t%10]) break;
      t/=10;
    }
    if(!t){ cout<<t<<endl; break;}
    n++;
  }
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:50:10: error: 'f' was not declared in this scope
   50 |       if(f[t%10]) break;
      |          ^
Language: C++

#include <stdio.h>
#include <iostream>
using namespace std;
bool like(char p,int *L,int len)
{
	int d= p - '0';
	for (int i=0;i<len;i++){
		if (L[i]==d){
			return true;
		}
	}
	return false;
}
int getMin(char p,int *L,int len)
{
	int d= p - '0';
	for (int i=0;i<len;i++){
		if (L[i]>d){
			return L[i];
		}
	}
	return -1;
}
int main(int argc, char* argv[])
{
	int N,K;
	cin>>N>>K;
	int D[10];
	int L[10];
	int i,j;
	int d;
	for (i=0;i<10;i++){
		D[i]=-1;
	}
	for (i=0;i<K;i++){
		cin>>d;
		D[d]=d;
	}
	j=0;
	for (i=0;i<10;i++){
		if (D[i]==-1){
			L[j++]=i;
		}
	}
	char S[10];
	sprintf(S,"%d",N);
	char *p=S;
	i=0;
	while (*p != '\0'){
		if (i==0){
			if (!like(*p,L,j)){
				i=1;
				continue;
			}
		}else{
			d=getMin(*p,L,j);
			if (d==-1){
				if (p==S){
					j=strlen(S);
					i=0;
					while (L[i]==0){
						i++;
					}
					S[0] = L[i];
					int k;
					for (k=1;k<j+1;k++){
						S[k]=L[0];
					}
					S[k] = '\0';
					cout<<S<<endl;
					return 0;
				}else{
					p--;
					continue;
				}
			}else{
				*p = d + '0';
				p++;
				while (*p != '\0'){
					*p = L[0] + '0';
					p++;
				}
				cout<<S<<endl;
				return 0;
			}
		}
		p++;
	}
	cout<<S<<endl;
	return 0;
}

Compiler output:
a.cc: In function 'int main(int, char**)':
a.cc:59:43: error: 'strlen' was not declared in this scope
   59 |                                         j=strlen(S);
      |                                           ^~~~~~
a.cc:3:1: note: 'strlen' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    2 | #include <iostream>
  +++ |+#include <cstring>
    3 | using namespace std;
Language: C++

#include <stdio.h>
#include <iostream>
using namespace std;
bool like(char p,int *L,int len)
{
	int d= p - '0';
	for (int i=0;i<len;i++){
		if (L[i]==d){
			return true;
		}
	}
	return false;
}
int getMin(char p,int *L,int len)
{
	int d= p - '0';
	for (int i=0;i<len;i++){
		if (L[i]>d){
			return L[i];
		}
	}
	return -1;
}
int main(int argc, char* argv[])
{
	int N,K;
	cin>>N>>K;
	int D[10];
	int L[10];
	int i,j;
	int d;
	for (i=0;i<10;i++){
		D[i]=-1;
	}
	for (i=0;i<K;i++){
		cin>>d;
		D[d]=d;
	}
	j=0;
	for (i=0;i<10;i++){
		if (D[i]==-1){
			L[j++]=i;
		}
	}
	char S[10];
	sprintf(S,"%d",N);
	char *p=S;
	i=0;
	while (*p != '\0'){
		if (i==0){
			if (!like(*p,L,j)){
				i=1;
				continue;
			}
		}else{
			d=getMin(*p,L,j);
			if (d==-1){
				if (p==S){
					j=strlen(S);
					i=0;
					while (L[i]==0){
						i++;
					}
					S[0] = L[i];
					for (int k=1;k<j+1;j++){
						S[k]=L[0];
					}
					S[K] = '\0';
					cout<<S<<endl;
					return 0;
				}else{
					p--;
					continue;
				}
			}else{
				*p = d + '0';
				p++;
				while (*p != '\0'){
					*p = L[0] + '0';
					p++;
				}
				cout<<S<<endl;
				return 0;
			}
		}
		p++;
	}
	cout<<S<<endl;
	return 0;
}

Compiler output:
a.cc: In function 'int main(int, char**)':
a.cc:59:43: error: 'strlen' was not declared in this scope
   59 |                                         j=strlen(S);
      |                                           ^~~~~~
a.cc:3:1: note: 'strlen' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    2 | #include <iostream>
  +++ |+#include <cstring>
    3 | using namespace std;
Language: C++

#include<cstdio>
#include<set>
#include<algorithm>
using namespace std;
int len,k;
char c[10];
int bit[10];
int dis[10],to[10];
int fir;
void go()
{//puts("__");
    int wei=len;
    for(int i=1;i<=wei;i++)
    {
        if(to[bit[i]]==-1)
        {
            bit[i]=fir,bit[i+1]++;
            if(i==len)wei=len+1;
        }
        else bit[i]=to[bit[i]];
    }
    if(bit[wei]==0)wei--;
    for(int i=wei+1;i;i--)printf("%d",bit[i]);puts("");
}
int main()
{
    while(~scanf("%s%d",c+1,&k))
    {
        len=strlen(c+1);
        for(int i=1;i<=len;i++)bit[i]=c[len+1-i]-'0';bit[len+1]=0;
        memset(dis,0,sizeof dis);
        fir=9;
        while(k--)
        {
            int x;scanf("%d",&x);dis[x]=1;
        }
        for(int i=0;i<=9;i++)
        {
            if(!dis[i])
            {
                fir=i;break;
            }
        }
        for(int i=0;i<=9;i++)
        {
            to[i]=-1;
            for(int j=i;j<=9;j++)
            {
                if(!dis[j])
                {
                    to[i]=j;break;
                }
            }
        }
        go();
    }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:29:13: error: 'strlen' was not declared in this scope
   29 |         len=strlen(c+1);
      |             ^~~~~~
a.cc:4:1: note: 'strlen' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    3 | #include<algorithm>
  +++ |+#include <cstring>
    4 | using namespace std;
a.cc:31:9: error: 'memset' was not declared in this scope
   31 |         memset(dis,0,sizeof dis);
      |         ^~~~~~
a.cc:31:9: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
Language: C

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

int main()
{

        int n;
        int k;
        int d1;
        int d2;
        int d3;
        int d4;
        int d5;
        int d6;
        int d7;
        int d8;
        int d9;
        int d10;
        int i;
        int cnt0;
        int cnt1;
        int cnt2;
        int cnt3;
        int cnt4;
        int cnt5;
        int cnt6;
        int cnt7;
        int cnt8;
        int cnt9;
        int a;


	// 個数のの入力
        scanf("%d %d",&n,&k);
        scanf("%d %d %d %d %d %d %d %d %d %d ",&d1,&d2,&d3,&d4,&d5,&d6,&d7,&d8,&d9,&d10);

        a = (int)log10(n) + 1;

        if (k == 1) {
           if (d1 == 0) {
	       printf("%d\n",n);
           }
        } 
  
        if  (d1 == 0 ) {
            cnt0 = cnt0 + 1;   
　　　　}
	return 0;
}


Compiler output:
main.c: In function 'main':
main.c:49:1: error: stray '\343' in program
   49 | <U+3000><U+3000><U+3000><U+3000>}
      | ^~~~~~~~
main.c:49:3: error: stray '\343' in program
   49 | <U+3000><U+3000><U+3000><U+3000>}
      |         ^~~~~~~~
main.c:49:5: error: stray '\343' in program
   49 | <U+3000><U+3000><U+3000><U+3000>}
      |                 ^~~~~~~~
main.c:49:7: error: stray '\343' in program
   49 | <U+3000><U+3000><U+3000><U+3000>}
      |                         ^~~~~~~~
Language: C

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

int main()
{

        int n;
        int k;
        int d1;
        int d2;
        int d3;
        int d4;
        int d5;
        int d6;
        int d7;
        int d8;
        int d9;
        int d10;
        int i;
        int cnt0;
        int cnt1;
        int cnt2;
        int cnt3;
        int cnt4;
        int cnt5;
        int cnt6;
        int cnt7;
        int cnt8;
        int cnt9;
        int a;


	// 個数のの入力
        scanf("%d %d",$n,&k);
        scanf("%d %d %d %d %d %d %d %d %d %d ",&d1,&d2,&d3,&d4,&d5,&d6,&d7,&d8,&d9,&d10);

        a = (int)log10(n) + 1;

        if (k == 1) {
           if (d1 == 0) {
	       printf("%d\n",n);
           }
        } 
	return 0;
}

Compiler output:
main.c: In function 'main':
main.c:36:23: error: '$n' undeclared (first use in this function); did you mean 'n'?
   36 |         scanf("%d %d",$n,&k);
      |                       ^~
      |                       n
main.c:36:23: note: each undeclared identifier is reported only once for each function it appears in
Language: C++

import java.io.InputStreamReader;
import java.util.Scanner;
 
public class Main {
	public static void main(String[] args) {
		try(Scanner scan = new Scanner(new InputStreamReader(System.in))){
			int N = scan.nextInt();
			int K = scan.nextInt();
			
			boolean[] D = new boolean[10];
			
			int min = 0;
			int minNot0 = 1;
			
			for(int i = 0; i<K; i++){
				int tmp = scan.nextInt();
				
				if(min == tmp){
					min++;
					minNot0 = min;
				}
				if(minNot0 == tmp){
					minNot0++;
				}
				D[tmp] = true;
			}
			
			String nStr = String.valueOf(N);
			StringBuffer ans = new StringBuffer();
			boolean isLarge = false;
			
			for(int i = 0; i<nStr.length(); i++){
				if(isLarge){
					ans.append(min);
				}else if(D[Character.digit(nStr.charAt(i),10)] == false){
					ans.append(nStr.charAt(i));
				}else{
					for(int j = Character.digit(nStr.charAt(i),10); j<K; j++){
						if(D[j] == false){
							ans.append(j);
							isLarge = true;
							break;
						}
					}
					if(isLarge == false){
						ans.append(minNot0);
						i--;
					}
				}
			}
			
			System.out.println(ans.toString());

		}
	}
}


Compiler output:
a.cc:1:1: error: 'import' does not name a type
    1 | import java.io.InputStreamReader;
      | ^~~~~~
a.cc:1:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:2:1: error: 'import' does not name a type
    2 | import java.util.Scanner;
      | ^~~~~~
a.cc:2:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:4:1: error: expected unqualified-id before 'public'
    4 | public class Main {
      | ^~~~~~
Language: C++

#include <stdio.h>
#include <cstdlib>
#include <string.h>
#include <math.h>
#include <string>
#include <vector>
#include <list>
#include <set>
#include <iostream>
#include <fstream>
#include <map>
#include <algorithm>
#include "windows.h"
//#include "../../gmp_int.h"
//#include "../../common.h"
#define MAX(a, b)		((a)>(b)?(a):(b))
#define MAX3(a, b, c)	(MAX((a),MAX((b),(c))))
#define FOR(a,b,c)		for (s32(a)=(b);(a)<(s32)(c);(a)++)
#define BL				{char bl[10];cin.getline(bl, 10);}
#define GL(c)			cin.getline(c, sizeof(c))
typedef char					s8;
typedef unsigned char			u8;
typedef short					s16;
typedef unsigned short			u16;
typedef int						s32;
typedef unsigned int			u32;
typedef long long int			s64;
typedef unsigned long long int	u64;
using namespace std;

//ifstream test_input;
//#define cin test_input


int main(int argc, char* argv[])
{
	cout.precision(15);

	s64 N, K, D[11];
	bool ok[11];
	cin >> N >> K;
	FOR(i, 0, 10) ok[i] = true;
	FOR(i, 0, K) {
		cin >> D[i];
		ok[D[i]] = false;
	}
	for (s64 x = N;; x++) {
		s64 y = x;
		bool ng = false;
		while (y > 0) {
			if (!ok[y % 10]) {
				ng = true;
				break;
			}
			y /= 10;
		}
		if (!ng) {
			cout << x << endl;
			break;
		}
	}

	return 0;
}


Compiler output:
a.cc:13:10: fatal error: windows.h: No such file or directory
   13 | #include "windows.h"
      |          ^~~~~~~~~~~
compilation terminated.
Language: Java

import java.io.BufferedReader;
import java.io.FileReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

public class IrohasObsession {
	public static void main(String[] args) {
		InputReader r = new InputReader(System.in);
		int n = r.nextInt();
		int k = r.nextInt();
		boolean[] can = new boolean[10];
		for (int i = 0; i < k; i++) {
			can[r.nextInt()] = true;
		}
		for (int res = n;; res++) {
			int x = res;
			boolean win = true;
			while (x > 0) {
				int dig = x % 10;
				x /= 10;
				if (can[dig]) {
					win = false;
				}
			}
			if (win) {
				System.out.println(res);
				return;
			}
		}
	}

	static class InputReader {
		private BufferedReader reader;
		private StringTokenizer tokenizer;

		public InputReader(InputStream stream) {
			reader = new BufferedReader(new InputStreamReader(stream));
			tokenizer = null;
		}

		public InputReader(FileReader stream) {
			reader = new BufferedReader(stream);
			tokenizer = null;
		}

		public String nextLine() {
			try {
				return reader.readLine();
			} catch (IOException e) {
				// TODO Auto-generated catch block
				e.printStackTrace();
				return null;
			}
		}

		public String next() {
			while (tokenizer == null || !tokenizer.hasMoreTokens()) {
				try {
					tokenizer = new StringTokenizer(reader.readLine());
				} catch (IOException e) {
					throw new RuntimeException(e);
				}
			}
			return tokenizer.nextToken();
		}

		public int nextInt() {
			return Integer.parseInt(next());
		}

		public long nextLong() {
			return Long.parseLong(next());
		}

		public double nextDouble() {
			return Double.parseDouble(next());
		}
	}
}


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

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

ll mod=1000000007;
ll fact[200002];
ll ncr[200003];

ll power(ll a, ll b) {
    ll res = 1;
    while (b > 0) {
        if (b & 1)
            res=(res*a)%mod;
        
       b>>=1;
       a=(a*a)%mod;
       
    }

return res;
}

ll solve(ll x, ll y) {
    ll res = fact[x+y];
    res=(res*ncr[x])%mod;
    res=(res*ncr[y])%mod;
return rc;
}

int main() {
    fact[0]=1;
    ncr[0]= 1;
    for(int x=1; x<=200000;x++) {fact[x] = (x*fact[x-1])%mod;
        ncr[x] = power(fact[x],mod-2);
    }

    ll h,w,a,b;
    cin>>h>>w>>a>>b;
    ll y= h-a-1;
    ll ans = 0;
    for(int i=b;i<w;i++) {
        ll r1=solve(y,i);
        ll r2=solve(h-y-2,w-i-1);

        ans+=(r1*r2)%mod;
        ans=ans%mod;
    }

    cout<<ans<<endl;

}



Compiler output:
a.cc: In function 'll solve(ll, ll)':
a.cc:27:8: error: 'rc' was not declared in this scope
   27 | return rc;
      |        ^~
Language: C++

#include<bits/stdc++.h>
 using namespace std;
 typedef long long LL;
 const int P = 1000000007;
 LL f[1000001], v[1000001];
 LL rp(LL now, int k) 
 {
     LL will = 1;
     for (; k; k >>= 1, now *= now, now %= P) 
     {
         if (k & 1) will *= now, will %= P;
     }
     return will;
 }
 LL C(int n, int m) 
 {
     if(n < m) return 0;
     if(m == 0) return 1;
     return f[n] * rp(f[m], P - 2) % P * rp(f[n - m], P - 2) % P;
 }
 void init()
 {
     f[0] = 1; v[0] = 1;
     for (int i = 1; i <= 1000000; i++) //1e6以  内的组合数
     {
         f[i] = f[i - 1] * i % P;
     }
 }
 int main() 
 {
    init();
    int h, w, a, b;
    cin >> h >> w >> a >> b;
    LL ans = 0;
    for(int i = b + 1; i <= w; i++) {·
       // printf("C(%d, %d)\n", (h - a) + (b + i) - 2, h - a - 1);
        // printf("C(%d, %d)\n", a + (w - b - i + 1), a - 1);
        LL tmp = C((h - a) + i - 2, i - 1) * C(a + (w - i + 1) - 2, w - i) % P;
        ans = (ans + tmp) % P;
    }
    cout << ans << endl;
 }

Compiler output:
a.cc: In function 'int main()':
a.cc:35:38: error: '\U000000b7' was not declared in this scope
   35 |     for(int i = b + 1; i <= w; i++) {·
      |                                      ^
a.cc:39:22: error: 'tmp' was not declared in this scope; did you mean 'tm'?
   39 |         ans = (ans + tmp) % P;
      |                      ^~~
      |                      tm
Language: C++

#include<iostream>
#include<cstring>
using namespace std;

const int maxn = 1e5 + 5;
const int mod = 1e9 + 7;
int dp[maxn][maxn];
int h, w, a, b;

bool range(int i, int j)
{
	return i <= h - 1 && i >= h - a && j >= 0 && j < b;
}

int main()
{
	memset(dp, 0, sizeof(dp));
	cin >> h >> w >> a >> b;
	for(int i = 0; i < h; i ++)
		if(!range(i, 0))	dp[i][0] = 1;
	for(int i = 0; i < w; i ++)
		if(!range(0, i))	dp[0][i] = 1;
	for(int i = 1; i < h; i ++)
	{
		for(int j = 1; j < w; j ++)
			if(!range(i, j))	dp[i][j] = (dp[i - 1][j] + dp[i][j - 1]) % mod;
	}
	cout << dp[h - 1][w - 1] << endl;
}

Compiler output:
/tmp/ccT85Zcu.o: in function `range(int, int)':
a.cc:(.text+0xc): relocation truncated to fit: R_X86_64_PC32 against symbol `h' defined in .bss section in /tmp/ccT85Zcu.o
a.cc:(.text+0x17): relocation truncated to fit: R_X86_64_PC32 against symbol `h' defined in .bss section in /tmp/ccT85Zcu.o
a.cc:(.text+0x1d): relocation truncated to fit: R_X86_64_PC32 against symbol `a' defined in .bss section in /tmp/ccT85Zcu.o
a.cc:(.text+0x30): relocation truncated to fit: R_X86_64_PC32 against symbol `b' defined in .bss section in /tmp/ccT85Zcu.o
/tmp/ccT85Zcu.o: in function `main':
a.cc:(.text+0x73): relocation truncated to fit: R_X86_64_PC32 against symbol `h' defined in .bss section in /tmp/ccT85Zcu.o
a.cc:(.text+0x8f): relocation truncated to fit: R_X86_64_PC32 against symbol `w' defined in .bss section in /tmp/ccT85Zcu.o
a.cc:(.text+0xa4): relocation truncated to fit: R_X86_64_PC32 against symbol `a' defined in .bss section in /tmp/ccT85Zcu.o
a.cc:(.text+0xb9): relocation truncated to fit: R_X86_64_PC32 against symbol `b' defined in .bss section in /tmp/ccT85Zcu.o
a.cc:(.text+0x107): relocation truncated to fit: R_X86_64_PC32 against symbol `h' defined in .bss section in /tmp/ccT85Zcu.o
a.cc:(.text+0x150): relocation truncated to fit: R_X86_64_PC32 against symbol `w' defined in .bss section in /tmp/ccT85Zcu.o
a.cc:(.text+0x231): additional relocation overflows omitted from the output
collect2: error: ld returned 1 exit status
Language: C++

#include<bits/stdc++.h>
#define Mod 1000000007
#define Val(x) (((long long)x) % Mod)
#define maxn 200005
using namespace std;
int fac[maxn];
int Pow(int a,int n) {
	int ret = 1;
	int base = a;
	while(n) {
		if(n&1)	ret = Val(ret*base);
		base = Val(base*base);
		n >>= 1;
	}
	return ret;
}
int cal(int n,int m) {
	return Val(Val(fac[n+m]*Pow(fac[n],Mod-2))*Pow(fac[m],Mod-2));
}
int main() {
	ios::sync_with_stdio(0);
	cin.tie(0);
	fac[0] = 1;
	for(int i=1;i<maxn;i++)a
		fac[i] = Val(fac[i-1] * i);
		
	int n,m,a,b;
	cin >> n >> m >> a >> b;
	
	int ans = 0;
	for(int j=b+1;j<=m;j++)
		ans = Val(ans + Val(cal(n-a-1,j-1)*cal(a-1,m-j)));
	
	cout << ans << endl;
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:24:32: error: 'a' was not declared in this scope
   24 |         for(int i=1;i<maxn;i++)a
      |                                ^
Language: C++

#include <iostream>
#include <vector>
 
using namespace std;
 
//combinationを作る前処理
vector<pair<long long, long long> > prime_factorize(long long n) {
    vector<pair<long long, long long> > res;
    for (long long p = 2; p * p <= n; ++p) {
        if (n % p != 0) continue;
        int num = 0;
        while (n % p == 0) { ++num; n /= p; }
        res.push_back(make_pair(p, num));
    }
    if (n != 1) res.push_back(make_pair(n, 1));
    return res;
}
 
const int MAX = 210000;
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(){
  
  long long int H , W , A , B;
  
  cin >> H >> W >> A >> B;
  
  COMinit();
  
  long long int ans = 0;
  
  for(int i=0;i<W-B;i++){
    
    ans += (com(A+W-B-i,A)*com(H-A-1+B+i,H-A-1))%1000000007
      ans %= 1000000007;
    
  }
  
  cout << ans << endl;
  
}
    

Compiler output:
a.cc: In function 'int main()':
a.cc:55:60: error: expected ';' before 'ans'
   55 |     ans += (com(A+W-B-i,A)*com(H-A-1+B+i,H-A-1))%1000000007
      |                                                            ^
      |                                                            ;
   56 |       ans %= 1000000007;
      |       ~~~
Language: C

#include<cstdio>
#include<iostream>

#define int long long

const int mod=1e9+7;
const int maxn=1e5+10;

int h,w,a,b,ans;
int f[maxn<<1];

inline int read(){
    char ch=getchar();int x=0,f=1;
    while(ch>'9'||ch<'0'){if(ch=='-')f=-1;ch=getchar();}
    while(ch<='9'&&ch>='0'){x=x*10+ch-'0';ch=getchar();}
    return x*f;
}

inline int ksm(int x,int y){
    x%=mod;
    int res=1;
    while(y){
        if(y&1) (res*=x)%=mod;
        (x*=x)%=mod;
        y>>=1;
    }
    return res%mod;
}

inline int get(int x1,int y1,int x2,int y2){
    int n=x2-x1+y2-y1,m=x2-x1;
    return ( f[n]*ksm( f[m]*f[n-m] , mod-2 ) )%mod;
}

signed main(){
    h=read(),w=read(),a=read(),b=read();
    f[0]=f[1]=1;
    for(register int i=2;i<=(maxn<<1);i++)
        (f[i]=f[i-1]*i)%=mod;
    for(register int i=1;i<=h-a;i++){
        (ans+=get(1,1,i,b)*get(i,b+1,h,w))%=mod;
    }
    std::cout<<ans<<std::endl;
    return 0;
}

Compiler output:
main.c:1:9: fatal error: cstdio: No such file or directory
    1 | #include<cstdio>
      |         ^~~~~~~~
compilation terminated.