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

 <cstdio>

using namespace std;

int card[256];

int main()
{
    int n;

    while (scanf("%d", &n), n){
        for (int i = 1; i < n * 2 + 1; i++){
            card[i] = 2;
        }

        for (int i = 0; i < n; i++){
            int pass;
            scanf("%d", &pass);

            card[pass] = 1;
        }

        int i = 0;
        int turn = 1;
        int now = 1;
        int hand[2] = {n, n};

        while (hand[0] && hand[1]){
            if (card[now] == turn){
                card[now] = 0;
                hand[turn - 1]--;
                turn = turn == 1 ? 2 : 1;
            }
            now++;

            if (now > n * 2 + 1){
                now = 1;
                turn = turn == 1 ? 2 : 1;
            }
        }

        printf("%d\n", hand[1]);
        printf("%d\n", hand[0]);
    }

    return (0);
}

Compiler output:
a.cc:1:2: error: expected unqualified-id before '<' token
    1 |  <cstdio>
      |  ^
a.cc: In function 'int main()':
a.cc:11:12: error: 'scanf' was not declared in this scope
   11 |     while (scanf("%d", &n), n){
      |            ^~~~~
a.cc:42:9: error: 'printf' was not declared in this scope
   42 |         printf("%d\n", hand[1]);
      |         ^~~~~~
a.cc:1:1: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
  +++ |+#include <cstdio>
    1 |  <cstdio>
Language: C++

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

void elim(vector<int> *tmp,int cnt){
  vector<int>::iterator ite=tmp->begin();
  for(int i=0;i<cnt;i++){
    ite++;
  }
  tmp->erase(ite);
}

int main(){
  int n;
  while(cin>>n){
    if(n==0)break;
    int tmp;
    vector<int> a,b;
    for(int i=0;i<n;i++){
      cin>>tmp;
      a.push_back(tmp);
    }
    sort(a.begin(),a.end());
    int cnt=0;
    for(int i=1;i<=2*n;i++){
      if(a[cnt]>i){
	b.push_back(i);
      }else{
	cnt++;
      }
    }
    int num=0;
    bool flg=false;
    while(a.empty()!=true && 
	  b.empty()!=true){
      cnt=0;
      for(int i:a){
	if(i>num){
	  num=i;
	  elim(&a,cnt);
	  flg=true;
	  break;
	}
	cnt++;
      }
      if(flg==false)num=0;
      flg=false;
      cnt=0;
      for(int i: b){
	if(i>num){
	  num=i;
	  elim(&b,cnt);
	  flg=true;
	  break;
	}
	cnt++;
      }
      if(flg==false)num=0;
      flg=false;
    }
    cout << b.size() << endl;
    cout << a.size() << endl;
  }
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:23:5: error: 'sort' was not declared in this scope; did you mean 'short'?
   23 |     sort(a.begin(),a.end());
      |     ^~~~
      |     short
Language: C++

#include <cstdio>
#include <cstdlib>
#include <iostream>
#include <string>
#include <cmath>
#include <algorithm>
#include <vector>
#include <queue>
#include <stack>
#include <map>
#include <set>

using namespace std;


void slove(int n){
    int card[202]={0},no[2],in,ba=0,ban=1;
    
    
    no[0]=no[1]=n;
    
    for(int i=0;i<n;i++){
        scanf("%d",&in);
        card[in]=1;
    }
    
    
    
    while(1){
        for(int i=ba+1;;i++){
            if(2*n<i){
                ba=0;
                ban=1-ban;
                break;
            }
            if(card[i]==ban){
                no[ban]--;
                card[i]=-1;
                ba=i;
                ban=1-ban;
                break;
            }
        }
        if(no[0]*no[1]==0){
            printf("%d\n%d\n",no[0],no[1]);
            return;
        }
    }
    
    
    return;
}

int main(){
    while(1){
        scanf("%d",&n);
        if(!n) break;
        slove(n);
    }
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:56:21: error: 'n' was not declared in this scope; did you mean 'yn'?
   56 |         scanf("%d",&n);
      |                     ^
      |                     yn
Language: C++

#include <stdio.h>

int main(void) {
	int n, i, top, buf, num, cou[2], turn, cards[2][100], bufcou, deglis[200];

	while(scanf("%d", &n)){
		if(n == 0)break;
		top = 0;
		cou[0] = n;
		cou[1] = n;
		turn = 1;
		bufcou = 0;
		memset(deglis, 0, sizeof(deglis));
	for (i = 0; n > i; i++){
		scanf("%d", &cards[0][i]);
		deglis[cards[0][i] - 1] = 1;
	}
	for (i = 0; n*2 > i; i++){
		if (deglis[i] == 0){
			cards[1][bufcou] = i + 1;
			bufcou++;
		}
	}

	while (1){
		turn = 1 - turn;
		buf = 201;
		for (i = 0; n > i; i++) if (buf > cards[turn][i] && top < cards[turn][i]) {
			buf = cards[turn][i];
			num = i;
		}

		if (buf == 201) {top = 0; continue;}
		top = buf;
		cards[turn][num] = 0;
		cou[turn]--;
		if (cou[turn] == 0) break;
		
	}
	printf("%d\n%d\n", cou[1], cou[0]);
}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:17: error: 'memset' was not declared in this scope
   13 |                 memset(deglis, 0, sizeof(deglis));
      |                 ^~~~~~
a.cc:2:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    1 | #include <stdio.h>
  +++ |+#include <cstring>
    2 |
Language: C++

#include<bits/stdc++.h>
using namespace std;
bool A[200],B[200];
int N;
void change(bool *C,int &c,int &fld){
    for(int i=fld+1;i<2*N;i++){
        if(C[i]){
            C[i]=false;
            c--;
            fld=i;
            return;
        }
    }
    fld=-1;
}
void solve(){
    int a,b,fld=-1;
    a=b=N;
    for(int i=0;i<N;i++){
        int x;
        scanf("%d",&x);
        A[--x]=true;
        B[x]=false;
    }

    while(a&&b){
        if(i%2)change(B,b,fld);
        else change(A,a,fld);
    }
    printf("%d\n%d\n",b,a);
}

int main(){
    while(scanf("%d",&N),N){
        fill_n(A,2*N,false);
        fill_n(B,2*N,true);
        solve();
    }
    return 0;
}

Compiler output:
a.cc: In function 'void solve()':
a.cc:27:12: error: 'i' was not declared in this scope
   27 |         if(i%2)change(B,b,fld);
      |            ^
Language: C++

#include <iostream>

using std::cin;
using std::cout;

int n;

class mine
{
  private:
	int a;
  public:
	mine(void){a=1;}
	int get{return a;}
	void change{a==1?a=2:a=1;}
};
mine turn();

int main()
{
	std::ios::sync_with_stdio(false);
	
	int c[200];
	int s[2];
	int ba;
	int cnt;
	
	while(cin>>n&&n!=0)
	{	
		for(int i=0;i<n*2;++i)
		{
			c[i]=2;
		}		
		s[0]=0;
		s[1]=0;
		ba=-1;
		
		for(int i=0;i<n;i++)
		{
			int j;
			cin>>j;
			c[j-1]=1;
		}
		while(true)
		{
			//game
			for(int i=0;i<n*2;++i)
			{
				if(ba<c[i]&&c[i]==turn.get())
				{
					ba=i;
					c[i]=0;
					cnt++;
				}
				else{++cnt;}
			}
			turn.change();
			if(cnt==0)
			{
				int score;
				for(int i=0;i<n*2;++i)
				{
					if(c[i]==turn.get())score++;
				}
				s[turn.get()-1;]=score;
				break;
			}
			cnt=0;
		}
		cout<<s[0]<<"\n"<<s[1]<<"\n";
	}
	return 0;
}

Compiler output:
a.cc:14:26: error: expected ';' at end of member declaration
   14 |         int get{return a;}
      |                          ^
      |                           ;
a.cc:15:14: error: variable or field 'change' declared void
   15 |         void change{a==1?a=2:a=1;}
      |              ^~~~~~
a.cc:15:34: error: expected ';' at end of member declaration
   15 |         void change{a==1?a=2:a=1;}
      |                                  ^
      |                                   ;
a.cc:14:17: error: expected primary-expression before 'return'
   14 |         int get{return a;}
      |                 ^~~~~~
a.cc:14:17: error: expected '}' before 'return'
a.cc:14:16: note: to match this '{'
   14 |         int get{return a;}
      |                ^
a.cc:14:17: error: cannot convert '<brace-enclosed initializer list>' to 'int' in initialization
   14 |         int get{return a;}
      |                 ^~~~~~
a.cc:14:17: error: expected ';' before 'return'
a.cc: In function 'int main()':
a.cc:49:56: error: request for member 'get' in 'turn', which is of non-class type 'mine()'
   49 |                                 if(ba<c[i]&&c[i]==turn.get())
      |                                                        ^~~
a.cc:57:30: error: request for member 'change' in 'turn', which is of non-class type 'mine()'
   57 |                         turn.change();
      |                              ^~~~~~
a.cc:63:55: error: request for member 'get' in 'turn', which is of non-class type 'mine()'
   63 |                                         if(c[i]==turn.get())score++;
      |                                                       ^~~
a.cc:65:40: error: request for member 'get' in 'turn', which is of non-class type 'mine()'
   65 |                                 s[turn.get()-1;]=score;
      |                                        ^~~
a.cc:65:47: error: expected ']' before ';' token
   65 |                                 s[turn.get()-1;]=score;
      |                                               ^
      |                                               ]
a.cc:65:48: error: expected primary-expression before ']' token
   65 |                                 s[turn.get()-1;]=score;
      |                                                ^
Language: C++

#include <iostream>
#include <cstdio>
#include <algorithm>
#include <functional>
#include <vector>
#include <string>
??
#define rep(i,n) for(int i=0;i<n;i++)
using namespace std;
??
vector<int> game(vector<int> t, vector<int> h, int n){
??????????
????????int turn = 1; //1=taro 0=hana
????????int field = 0, f; 
????????vector<int> res;
??
????????sort(t.begin(),t.end());
????????sort(h.begin(),h.end());
??????????
????????while(1){
??????????????????
????????????????f = 1;
??????????
????????????????if(turn){???? 
????????????????????????rep(i,t.size()){
????????????????????????????????if(field < t[i]){
??????????????????????????????????????????
//?????????????????????????????????? cout << "taro -> " << t[i] << endl;
??????????????????????????????????????????
????????????????????????????????????????field = t[i];
????????????????????????????????????????t.erase(remove(t.begin(), t.end(), t[i]), t.end()); 
????????????????????????????????????????f = 0;
????????????????????????????????????????break;
????????????????????????????????}
????????????????????????}
????????????????????????turn = 0;
????????????????}
????????????????else{
????????????????????????rep(i, h.size()){
????????????????????????????????if(field < h[i]){
??
//?????????????????????????????????? cout << "hana -> " << h[i] << endl;
??
????????????????????????????????????????field = h[i];
????????????????????????????????????????h.erase(remove(h.begin(), h.end(), h[i]), h.end()); 
????????????????????????????????????????f = 0;
????????????????????????????????????????break;
????????????????????????????????}
????????????????????????}
????????????????????????turn = 1;
????????????????}
??????????????????
????????????????if(f) field = 0;
??
????????????????if(t.empty() || h.empty()) break;
????????}???????????? 
??????????
????????res.push_back(h.size());
????????res.push_back(t.size());
??
????????return res;
}
??
int main(){
????????int n;
??????????
????????while(cin >> n, n){
??????????
????????vector<int> taro,hana,res;
????????int m;
??????????
????????rep(i,n*2) hana.push_back(i+1);
??????????
??
????????rep(i,n){
????????????????cin >> m;
????????????????taro.push_back(m);
????????????????hana.erase(remove(hana.begin(), hana.end(), m), hana.end());
????????}
????????//rep(i,n) cout << taro[i] << "\n";
????????//rep(i,n) cout << hana[i] << "\n";
??
????????res = game(taro,hana,n);
??
????????rep(i,2) cout << res[i] << "\n";
??????????
????????}
????????return 0;
}

Compiler output:
a.cc:80:7: warning: trigraph ??/ ignored, use -trigraphs to enable [-Wtrigraphs]
   80 | ????????//rep(i,n) cout << taro[i] << "\n";
a.cc:81:7: warning: trigraph ??/ ignored, use -trigraphs to enable [-Wtrigraphs]
   81 | ????????//rep(i,n) cout << hana[i] << "\n";
a.cc:7:1: error: expected unqualified-id before '?' token
    7 | ??
      | ^
a.cc:10:1: error: expected unqualified-id before '?' token
   10 | ??
      | ^
a.cc:63:1: error: expected unqualified-id before '?' token
   63 | ??
      | ^
Language: C++

#include <iostream>
#include <set>
#include <algorithm>
using namespace std;
set<int> tro,hnk;
set<int>::iterator it;
int main(){
	int N,hog,ba,ta,ha;
	while(1){
		cin>>N;
		if(N==0) break;
		tro.clear();
		hnk.clear();
		for(int i=0;i<N;i++){
			cin>>hog;
			tro.insert(hog);
		}
		for(int i=1;i<=N*2;i++){
			if(tro.find(i)==tro.end()){
				hnk.insert(i);
			}
		}

		ba=ta=ha=0;
		while(1){
			//??????
			if(ba==0){
				it=tro.begin();
				ba=*it;
				tro.erase(*it);
			}
			else{
				it=tro.upper_bound(ba);
				if(it==tro.end()){
					ba=0;
				}
				else{
					ba=*it;
					tro.erase(*it);
				}
			}
			
			if(tro.empty()){
				for(it=hnk.begin();it!=hnk.end();it++){
					ha++;
				}
				break;
			}

			//??±???
			if(ba==0){
				it=hnk.begin();
				ba=*it;
				hnk.erase(*it);
			}
			else{
				it=hnk.upper_bound(ba);
				if(it==hnk.end()){
					ba=0;
				}
				else{
					ba=*it;
					hnk.erase(*it);
				}
			}
			
			if(hnk.empty()){
				for(it=tro.begin();it!=tro.end();it++){
					ta++;
				}
				break;
			}
		}
		cout<<ha<<endl<<ya<<endl;
	}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:74:33: error: 'ya' was not declared in this scope; did you mean 'ha'?
   74 |                 cout<<ha<<endl<<ya<<endl;
      |                                 ^~
      |                                 ha
Language: C++

let rec solve() = 
  let rec input = function
    | 0 -> []
    | n -> Scanf.scanf "%d\n" (fun x -> x::input (n - 1)) in
  let rec ura i n = function
    | [] -> if i > n then [] else i::ura (i + 1) n []
    | w::d as q -> if i = w then ura (i + 1) n d else i::ura (i + 1) n q in
  let rec last p l a b =
    let rec can n = function
      | [] -> (0,[])
      | w::d -> if n < w then (w,d) else
          let (w1,w2) = can n d in
          (w1,w::w2) in
    let rec count = function
      | [] -> 0
      | w::d -> w + count d in

    let (pp,ll,aa,bb) = if p then
      let (w1,w2) = can l a in
      (false,w1,w2,b)
    else
      let (w1,w2) = can l b in
      (true,w1,a,w2) in
    if aa = [] || bb = [] then (count aa,count bb) else last pp ll aa bb in

  let n = Scanf.scanf "%d\n" (fun x -> x) in
  if n = 0 then () else begin
    let d1 = List.sort compare (input n) in
    let d2 = ura 1 (n * 2) d1 in
    let (a,b) = last true 0 d1 d2 in
    Printf.printf "%d\n%d\n" b a;
    solve() end

let _ = solve()

Compiler output:
a.cc:1:1: error: 'let' does not name a type
    1 | let rec solve() =
      | ^~~
a.cc:32:13: error: expected constructor, destructor, or type conversion before 'end'
   32 |     solve() end
      |             ^~~
Language: C++

#include <iostream>

int main(){
cout << "????????´??????SEX???" << endl;
return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:4:1: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    4 | cout << "????????´??????SEX???" << endl;
      | ^~~~
      | std::cout
In file included from a.cc:1:
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:4:36: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
    4 | cout << "????????´??????SEX???" << 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: C++

#include <iostream>
int cardnum;

int main(){
cin >> cardnum;
		if (cardnum == 0)break;
		vector<int> taro(cardnum), hanako;
		vector<bool> check(cardnum * 2, false);
		for (int i = 0; i < cardnum; i++)
		{
			cin >> taro[i];
			check[taro[i] - 1] = true;
		}
cout << "????????´??????SEX???" << endl;
return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:1: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    5 | cin >> cardnum;
      | ^~~
      | 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:6:34: error: break statement not within loop or switch
    6 |                 if (cardnum == 0)break;
      |                                  ^~~~~
a.cc:7:17: error: 'vector' was not declared in this scope
    7 |                 vector<int> taro(cardnum), hanako;
      |                 ^~~~~~
a.cc:7:24: error: expected primary-expression before 'int'
    7 |                 vector<int> taro(cardnum), hanako;
      |                        ^~~
a.cc:8:24: error: expected primary-expression before 'bool'
    8 |                 vector<bool> check(cardnum * 2, false);
      |                        ^~~~
a.cc:11:32: error: 'taro' was not declared in this scope
   11 |                         cin >> taro[i];
      |                                ^~~~
a.cc:12:25: error: 'check' was not declared in this scope
   12 |                         check[taro[i] - 1] = true;
      |                         ^~~~~
a.cc:14:1: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   14 | cout << "????????´??????SEX???" << 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:14:36: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   14 | cout << "????????´??????SEX???" << 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: C++

#include<iostream>
using namespace std;
int main(){
	int n,card[201]={0},x,t,ba,i,cnt,c;
	while(1){
	cin>>n;
		if(n==0)
		break;
	for(i=0;i<n;i++){
		cin>>c;
		card[c]=1;
	}
	ba=0;
	t=0;
	x=0;
	cnt=0;
	while(1){
		if(ba==0){
			for(i=1;i<=2*n;i++){
				if(card[i]==(t+1)%2){
					ba=i;
					card[i]=2;
					break;
				}
			}
		}
		else{
			x=0;
			for(i=1;i<=2*n;i++){
				if(card[i]==(t+1)%2&&ba<i){
					ba=i;
					x=1;
					card[i]=2;
					break;
				}
			}
			if(x==0){
				ba=0;
			}
		}
		x=0;
		for(i=1;i<=2*n;i++){
			if(card[i]==1){
				x=2;
			}
		}
		if(x==0){
			break;
		}
		x=1;
		for(i=1;i<=2*n;i++){
			if(card[i]==0){
				x=2;
			}
		}
		if(x==1){
			break;
		}
		t++;
	}
	if(x==0){
		for(i=1;i<2*n;i++){
			if(card[i]==x){
				cnt++;
			}
		}
		cout<<cnt<<endl<<0<<endl;
	}
	else{
		for(i=1;i<2*n;i++){
			if(card[i]==x){
				cnt++;
			}
		}
		cout<<0<<endl<<cnt<<endl;
	}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:78:2: error: expected '}' at end of input
   78 | }
      |  ^
a.cc:3:11: note: to match this '{'
    3 | int main(){
      |           ^
Language: C++

#include "bits/stdc++.h"
using namespace std;
int solve(set<int> s,int a){
for(auto it=s.begin();it!=s.end();it++){
if(a<*it)
return *it;
}
return 0;
}
int calc(set<int> s){
int sum=0;
for(auto it=s.begin();it!=s.end();it++)
sum+=*it;
return sum;
}
int main(){
set<int> s1,s2;
bool f[201];
int n;
while(1){
cin>>n;
if(!n)break;
memset(f,false,sizeof(f));
for(int i=0;i<n;i++){
int tmp;
cin>>tmp;
f[tmp]=true;
s1.insert(tmp);
}
for(int i=1;i<=2*n;i++){
if(!f[i])s2.insert(i);
}
int field=0,turn=0;
while(!s1.empty||!s2.empty){
int card;
if(turn%2==0){
card=solve(s1,field);
s1.erase(card);
field=card;
}
else{
card=solve(s2,field);
s2.erase(card);
field=card;
}
turn++;
}
if(s1.empty){
cout<<calc(s2)<<endl;
cout<<0<<endl;
}
else{
cout<<0<<endl;
cout<<calc(s1)<<endl;
}
}
return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:34:11: error: cannot convert 'std::set<int>::empty' from type 'bool (std::set<int>::)() const noexcept' to type 'bool'
   34 | while(!s1.empty||!s2.empty){
      |           ^~~~~
a.cc:34:11: error: in argument to unary !
   34 | while(!s1.empty||!s2.empty){
      |        ~~~^~~~~
a.cc:34:22: error: cannot convert 'std::set<int>::empty' from type 'bool (std::set<int>::)() const noexcept' to type 'bool'
   34 | while(!s1.empty||!s2.empty){
      |                      ^~~~~
a.cc:34:22: error: in argument to unary !
   34 | while(!s1.empty||!s2.empty){
      |                   ~~~^~~~~
a.cc:48:12: error: cannot convert 'std::set<int>::empty' from type 'bool (std::set<int>::)() const noexcept' to type 'bool'
   48 | if(s1.empty){
      |            ^
Language: C++

//
//  main.cpp

#include <iostream>
#include <vector>
using namespace std;
const int TARO = 0;
const int HANAKO = 1;
vector<int> card[2];
int n;
int now=-1;
int turn = TARO;
//int hanakopoint,taropoint;

void search(){
	int Min = 10000;
	for(int i=0;i<card[turn].size();i++){
		if(now < card[turn][i]){
			Min = min(card[turn][i],Min);
		}
	}
	
	if(Min == 10000){
		now = -1;
	}else{
		now = Min;
		for(int i=0;i<card[turn].size();i++){
			if(card[turn][i] == now){
				card[turn].erase(card[turn].begin() + i);
				break;
			}
		}
	}
}

int main(){	
	while(1){
		bool check[201];
		
		for(int i=0;i<201;i++){
			check[i] = true;
		}
		card[TARO].clear();
		card[HANAKO].clear();

		cin >> n;
		if(n==0)break;
		int input;
		for(int i=0;i<n;i++){
			cin >> input;
			card[TARO].push_back(input);
			check[input] = false;
		}
		for(int i=1;i<=2*n;i++){
			if(check[i]){
				card[HANAKO].push_back(i);
			}
		}
		
		sort(card[TARO].begin(),card[TARO].end());
		sort(card[HANAKO].begin(),card[HANAKO].end());
		now = -1;
		turn = TARO;
		
		while(card[TARO].size() != 0 && card[HANAKO].size() != 0){
			search();
			if(turn){
				turn = TARO;
			}else{
				turn = HANAKO;
			}
		}
		cout << card[HANAKO].size() << endl << card[TARO].size() << endl;//????????????
	}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:60:17: error: 'sort' was not declared in this scope; did you mean 'short'?
   60 |                 sort(card[TARO].begin(),card[TARO].end());
      |                 ^~~~
      |                 short
Language: C++

#include <iostream>
#include <vector>
#include <algorithm>

int main(){
	int N;
	std::vector<int> taro, hanako;

	std::cin >> N;

	if(N == 0){
		break;
	}
	
	for(int i = 0; i < N; ++i){
		int input;
		std::cin >> input;
		taro.push_back(input);
	}

	for(int i = 1; i <= N * 2; ++i){
		if(std::find(taro.begin(), taro.end(), i) == taro.end()){
			hanako.push_back(i);
		}
	}

	std::sort(taro.begin(), taro.end());
	std::sort(hanako.begin(), hanako.end());

	bool is_taros_turn = true;
	while(!taro.empty() && !hanako.empty()){
		int card = 0;

		while(true){
			if(is_taros_turn){
				is_taros_turn = false;
				auto itr = taro.begin();
				bool flag = true;
				for(; itr != taro.end(); ++itr){
					if(*itr > card){
						flag = false;
						break;
					}
				}
				
				if(flag){
					card = 0;
					break;
				}
				
				card = *itr;
				taro.erase(itr);
				if(taro.empty()){
					break;
				}
			}
			else{
				is_taros_turn = true;
				auto itr = hanako.begin();
				bool flag = true;
				for(; itr != hanako.end(); ++itr){
					if(*itr > card){
						flag = false;
						break;
					}
				}
				
				if(flag){
					card = 0;
					break;
				}

				card = *itr;
				hanako.erase(itr);
				if(hanako.empty()){
					break;
				}
			}
		}
	}

	std::cout << hanako.size() << std::endl << taro.size() << std::endl;

	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:17: error: break statement not within loop or switch
   12 |                 break;
      |                 ^~~~~
Language: C++

#include <iostream>
using namespace std;
ios::sync_with_stdio(false);
int z[205], b;
int main(void) {
	int n, i, x, m[2],t;
	while (1){
		cin >> n;
		if (n == 0){ break; }
		for (i = 1; i <= 2 * n; i++){
			z[i] = 1;
		}
		for (i = 1; i <= n; i++){
			cin >> t;
			z[t] = 0;
		}
		
		m[0] = m[1] = n;
		x = 0;
		b = 0;
		while (m[0] > 0 && m[1] > 0){
			for (i = b+1; i <= 2 * n; i++){
				if (x == z[i]){
					b = i;
					z[i] = 2;
					m[x]--;
					break;
				}
				if (i > n * 2){
					b = 0;
				}
				x = !x;
			}
		}
		cout << m[1] << "\n" << m[0] << "\n";
	}
	return 0;
}

Compiler output:
a.cc:3:1: error: specializing member 'std::basic_ios<char>::sync_with_stdio' requires 'template<>' syntax
    3 | ios::sync_with_stdio(false);
      | ^~~
Language: C++

#include <iostream>
#include <vector>
using namespace std;
int main()
{
	int n;
	while(cin>>n,n){
		vector<int> taro,hana;
		int num[201];
		memset(num,0,sizeof(num));
		
		for(int i=0; i<n; i++){
			int a; cin>>a;
			num[a]=1;
		}
		
		for(int i=1; i<=2*n; i++){
			if( num[i] )taro.push_back(i);
			else 			hana.push_back(i);
		}
		
		int i,j,turn=1;
		int ba = 0;
		for(i=0,j=0; taro.size() && hana.size();){
			if( turn ){
				int k;
				for(k=0; k<taro.size(); k++)
					if( ba<taro[k] ){
						ba = taro[k];
						taro.erase( taro.begin()+k );
						break;
					}
				if( k==taro.size() )ba=0;
				
			}else{
				int k;
				for(k=0; k<hana.size(); k++)
					if( ba<hana[k] ){
						ba = hana[k];
						hana.erase( hana.begin()+k );
						break;
						//printf("h:%d\n",ba);
					}
				if( k==hana.size() )ba=0;
			}
			turn ^= 1;
		}

		printf("%d\n%d\n",hana.size(),taro.size());
	}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:17: error: 'memset' was not declared in this scope
   10 |                 memset(num,0,sizeof(num));
      |                 ^~~~~~
a.cc:3:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    2 | #include <vector>
  +++ |+#include <cstring>
    3 | using namespace std;
Language: C++

#include<iostream>
#include<vector>

using namespace std;

int check_c(int arr[], int nc);
int check_min(int arr[]);
int n;

int main()
{
	for(;;){
		int cont = 0, nowc, total = 0;
		int hcont, tcont;
		int temp;
		bool flg,nxflg, isgoto = 0;
		int arr[202];
		
		cin >> n;
		if(n == 0){
			break;
		}
		
		vector<int> taro(n);
		vector<int> hanako(n);
		for(int i = 0; i < n; i++){
			cin >> taro[i];
			arr[taro[i]] = 1;
		}
		for(int i = 1; i < n*2+1; i++){
			if(arr[i] == 1){
			}
			else{
				hanako[cont] = i;
				cont++;
			}
		}
		sort(taro.begin(), taro.end());
		sort(hanako.begin(), hanako.end());
		hcont = 0;
		tcont = 0;
		for(int i = 0;;i++){
			if(i == 0){
				nowc = taro[0];
				taro[0] = 0;
				tcont++;
				flg = 1;
			}
			
			if((isgoto == 1 && nxflg == 0)||(flg != 0 && nowc < hanako[check_c(&hanako[0], nowc)] && !isgoto)){
				if(!isgoto){
					temp = check_c(&hanako[0], nowc);
					nowc = hanako[temp];
					hanako[temp] = 0;
				}
				else{
					temp = check_min(&hanako[0]);
					nowc = hanako[temp];
					hanako[temp] = 0;
					isgoto = 0;
				}
				hcont++;
				flg = 0;
				nxflg = 0;
			}
			else if((isgoto == 1 && nxflg == 1)||(flg != 1 && nowc < taro[check_c(&taro[0], nowc)] && !isgoto)){
				if(!isgoto){
					temp = check_c(&taro[0], nowc);
					nowc = taro[temp];
					taro[temp] = 0;
				}
				else{
					temp = check_min(&taro[0]);
					nowc = taro[temp];
					taro[temp] = 0;
					isgoto = 0;
				}
				tcont++;
				flg = 1;
				nxflg = 1;
			}
			else{
				nowc = 0;
				isgoto = 1;
			}
			
			if(hcont == n || tcont == n){
				break;
			}
		}
		
		if(hcont == n){
			for(int i = 0; i < n; i++){
				if(taro[i] != 0){
					total++;
				}
			}
		cout << 0 << endl;
		cout << total << endl;
		}
		else{
			for(int i = 0; i < n; i++){
				if(hanako[i] != 0){
					total++;
				}
			}
			cout << total << endl;
			cout << 0 << endl;
		}
	}
	
}

int check_c(int arr[], int nc)
{
	for(int i = 0; i < n; i++){
		if(arr[i] > nc){
			return i;
		}
	}
	return 0;
}

int check_min(int arr[])
{
	for(int i = 0; i < n; i++){
		if(arr[i] > 0){
			return i;
		}
	}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:38:17: error: 'sort' was not declared in this scope; did you mean 'short'?
   38 |                 sort(taro.begin(), taro.end());
      |                 ^~~~
      |                 short
Language: C++

#include<stdio.h>

int main(){
while(1){
int n;
scanf("%d",&n);

if(n==0){
break;
}

int card[201];
for(int i=0;i<201;i++){
card[i]=0;
}

for(int i=1;i<=n;i++){
card[i]=2;
}

for(int i=0;i<n;i++){
int a;
scanf("%d",&a);
card[a]=1;
}


int turn=1;
int now=0;
while(1){
now++;

if(now>n){
now=0;
int con[3]={};
for(int i=1;i<=n;i++){
con[card[now]]++;
}
if(con[1]==0 || con[2]==0){
break;
}
continue;
}

if(turn==1){
if(card[now]==2){
card[now]=0;
}else{
if(card[now]==1){
card[now]=0;
}
}

}

int cont[3];
for(int i=1;i<=n;i++){
cont[card[i]]++;
}

printf("%d\n%d\n",cont[1],cont[2]);
}
return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:64:2: error: expected '}' at end of input
   64 | }
      |  ^
a.cc:3:11: note: to match this '{'
    3 | int main(){
      |           ^
Language: C++

#include <iostream>
#include <list>

using namespace std;

int main(void)
{
	char flag[201] = {0};
	int n;
	
	while (1){
		list<int> lst_taro, lst_hana;
		memset(flag, 0, 201);
		cin >> n;
		if (n == 0){
			break;
		}
		
		for (int i = 0; i < n; i++){
			int c;
			cin >> c;
			lst_taro.push_back(c);
			flag[c] = 1;
		}
		lst_taro.sort();
		for (int i = 1; i <= 2 * n; i++){
			if (flag[i] == 0){
				lst_hana.push_back(i);
			}
		}
		
		
		int field = 0;
		int count = 0;
		while (lst_taro.size() > 0 && lst_hana.size() > 0){
			list<int>::iterator it = count % 2 == 0 ? lst_taro.begin() : lst_hana.begin();
			list<int>::iterator end = count % 2 == 0 ? lst_taro.end() : lst_hana.end();
			
			while (it != end){
				if (*it > field){
					break;
				}
				it++;
			}
			if (it == end){
				field = 0;
			}
			else {
				field = *it;
				(count % 2 == 0 ? lst_taro : lst_hana).erase(it);
			}
			count++;
		}
		
		cout << lst_hana.size() << endl << lst_taro.size() << endl;
	}
	
	return (0);
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:17: error: 'memset' was not declared in this scope
   13 |                 memset(flag, 0, 201);
      |                 ^~~~~~
a.cc:3:1: note: 'memset' is defined in header '<cstring>'; this is probably fixable by adding '#include <cstring>'
    2 | #include <list>
  +++ |+#include <cstring>
    3 |
Language: C++

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

int main(){
  int n;
  vector<int> t,h;
  int tmp;
  int p,m;
  int i;

  while(1){
    cin >> n;
    if(!n)break;

    t.clear();
    for(i=0;i<n;i++){
      cin >> tmp;
      t.push_back(tmp);
    }
    sort(t.begin(),t.end());
    h.clear();
    int j = 0;
    for(i=1;i<=2*n;i++){
      if(t[j]!=i)h.push_back(i);
      else j++;
    }
    sort(h.begin(),h.end());

    p = 0;
    m = 0;
    while(1){
      if(!m){
	i = 0;
	while(i<t.size() && p>t[i])i++;
	if(i==t.size()){
	  p = 0;
	  m = 1;
	}else{
	  p = t[i];
	  t.erase(t.begin()+i);
	  if(!t.size())break;
	  m = 1;
	}
      }else{
	i = 0;
	while(i<h.size() && p>h[i])i++;
	if(i==h.size()){
	  p = 0;
	  m = 0;
	}else{
	  p = h[i];
	  h.erase(h.begin()+i);
	  if(!h.size())break;
	  m = 0;
	}
      }
    }
    cout << t.size() << endl << h.size() << endl;
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:21:5: error: 'sort' was not declared in this scope; did you mean 'short'?
   21 |     sort(t.begin(),t.end());
      |     ^~~~
      |     short
Language: C++

#include <iostream>

using namespace std;

const int TARO = 1, HANAKO = 2;

int main() {
  for (;;) {
    int n;
    cin >> n;
    if (!n) return 0;
    int L[201];
    fill(L, L+2*n+1, HANAKO);
    for (int i = 0; i < n; i++) {
      int x;
      cin >> x;
      L[x] = TARO;
    }
    int b = 0, t = n, h = n;
    for (bool s = true; t && h; s = !s) {
      int *p = find(L+1+b, L+2*n+1, s ? TARO : HANAKO);
      if (p == L+2*n+1)
        b = 0;
      else {
        b = p-L-1;
        *p = 0;
        (s ? t : h)--;
      }
    }
    printf("%d\n%d\n", h, t);
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:21:20: error: no matching function for call to 'find(int*, int*, const int&)'
   21 |       int *p = find(L+1+b, L+2*n+1, s ? TARO : HANAKO);
      |                ~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/14/bits/locale_facets.h:48,
                 from /usr/include/c++/14/bits/basic_ios.h:37,
                 from /usr/include/c++/14/ios:46,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/bits/streambuf_iterator.h:435:5: note: candidate: 'template<class _CharT2> typename __gnu_cxx::__enable_if<std::__is_char<_CharT2>::__value, std::istreambuf_iterator<_CharT> >::__type std::find(istreambuf_iterator<_CharT>, istreambuf_iterator<_CharT>, const _CharT2&)'
  435 |     find(istreambuf_iterator<_CharT> __first,
      |     ^~~~
/usr/include/c++/14/bits/streambuf_iterator.h:435:5: note:   template argument deduction/substitution failed:
a.cc:21:20: note:   mismatched types 'std::istreambuf_iterator<_CharT>' and 'int*'
   21 |       int *p = find(L+1+b, L+2*n+1, s ? TARO : HANAKO);
      |                ~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Language: C++

#include <iostream>
#include <vector>
#include <algorithm>

#define REP(i,n) for(int i=0;i<n;++i)

using namespace std;

//タロー→ハナァコォ

const int NONE = -1;

int main(void)
{
	while(1)
	{
		int n;
		vector<int> card[2];
		cin >> n;
		if(n==0)
			return 0;

		int field=NONE;//今場に出ているカード
		int turn=0;//0:太郎,1:花子;

		bool a[301]={};
		for(int i=0;i<n;++i)
		{
			int t;
			cin >> t;
			card[0].push_back(t);
			a[t] = true;
		}

		for(int i=1;i<=2*n;++i)
		{
			if(a[i] == false)
				card[1].push_back(i);
		}

		sort(card[0].begin(),card[0].end());
		sort(card[1].begin(),card[1].end());

		while(1)
		{
			if(card[1][0] == 0)
				card[1].erase(card[1].begin());
			else
				break;
		}

		while(1)
		{
			if(card[0].empty() || card[0].empty())
				break;
			if(field==NONE)
			{
				field = card[turn][0];
				card[turn].erase(card[turn].begin());
			}
			else
			{
				bool outFlag = false;
				for(int i=0;i<card[turn].size();++i)
				{
					if(field < card[turn][i])//出せるカードがある
					{
						field = card[turn][i];
						outFlag = true;
						//card[turn].erase(card[turn].begin()+i);
						card[turn].erase(card[turn].begin);
						break;
					}
				}
				if(outFlag == false)
				{
					field = NONE;
				}
			}
			if(turn==0) turn=1;
			else if(turn==1) turn=0;
		}
		int tsum=0;
		int hsum=0;
		for(int i=0;i<card[0].size();++i)
		{
			hsum += card[0][i];
		}
		for(int j=0;j<card[1].size();++j)
		{
			tsum += card[1][j];
		}
		cout << card[1].size() << endl;
		cout << card[0].size() << endl;
	}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:71:65: error: no matching function for call to 'std::vector<int>::erase(<unresolved overloaded function type>)'
   71 |                                                 card[turn].erase(card[turn].begin);
      |                                                 ~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/14/vector:66,
                 from a.cc:2:
/usr/include/c++/14/bits/stl_vector.h:1536:7: note: candidate: 'std::vector<_Tp, _Alloc>::iterator std::vector<_Tp, _Alloc>::erase(const_iterator) [with _Tp = int; _Alloc = std::allocator<int>; iterator = std::vector<int>::iterator; const_iterator = std::vector<int>::const_iterator]'
 1536 |       erase(const_iterator __position)
      |       ^~~~~
/usr/include/c++/14/bits/stl_vector.h:1536:28: note:   no known conversion for argument 1 from '<unresolved overloaded function type>' to 'std::vector<int>::const_iterator'
 1536 |       erase(const_iterator __position)
      |             ~~~~~~~~~~~~~~~^~~~~~~~~~
/usr/include/c++/14/bits/stl_vector.h:1564:7: note: candidate: 'std::vector<_Tp, _Alloc>::iterator std::vector<_Tp, _Alloc>::erase(const_iterator, const_iterator) [with _Tp = int; _Alloc = std::allocator<int>; iterator = std::vector<int>::iterator; const_iterator = std::vector<int>::const_iterator]'
 1564 |       erase(const_iterator __first, const_iterator __last)
      |       ^~~~~
/usr/include/c++/14/bits/stl_vector.h:1564:7: note:   candidate expects 2 arguments, 1 provided
Language: C++

#include <cstdio>
#include <list>

using namespace std;

#define TARO   0
#define HANAKO 1

char search(list<char>& target, char num) {
    list<char>::iterator it = target.begin();

    while (1) {
        if (it == target.end()) return 0;
        if (*it > num) {
            char ret = *it;
            target.erase(it);
            return ret;
        }
        it++;
    }
}

int main() {
    while (1) {
        int i;
        int n;
        vector<bool> flag(200);
        list<char> Taro;
        list<char> Hanako;
        char save;
        bool turn;

        scanf("%d", &n);
        if (n == 0) return 0;


        for (i=0;i<n;i++) {
            int k;

            scanf("%d", &k);
            Taro.push_back(k);
            flag[k-1] = 1;
        }

        for (i=0;i<2*n;i++) {
            if (!flag[i]) {
                Hanako.push_back(i);
            }
        }

        Taro.sort();
        Hanako.sort();

        turn = TARO;
        save = 0;
        while (1) {
            if (turn == TARO) {
                save = search(Taro, save);
                turn = HANAKO;
            } else {
                save = search(Hanako, save);
                turn = TARO;
            }

            if (Taro.empty() || Hanako.empty()) break;
        }

        printf("%d\n", Hanako.size());
        printf("%d\n", Taro.size());
    }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:27:9: error: 'vector' was not declared in this scope
   27 |         vector<bool> flag(200);
      |         ^~~~~~
a.cc:3:1: note: 'std::vector' is defined in header '<vector>'; this is probably fixable by adding '#include <vector>'
    2 | #include <list>
  +++ |+#include <vector>
    3 | 
a.cc:27:16: error: expected primary-expression before 'bool'
   27 |         vector<bool> flag(200);
      |                ^~~~
a.cc:42:13: error: 'flag' was not declared in this scope
   42 |             flag[k-1] = 1;
      |             ^~~~
a.cc:46:18: error: 'flag' was not declared in this scope
   46 |             if (!flag[i]) {
      |                  ^~~~
Language: C++

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

int main(){
int n,i,j,a,suu1,suu2,ba,t;
int tarou[100];
int hanako[100];
while(1){
scanf("%d",&n);
if(n==0)break;

for(i=0;i<n;i++)tarou[i]=0;hanako[i]=0;
for(i=0;i<n;i++)scanf("%d",&tarou[i]);
for(i=0;i<n;i++){
for(j=0;j<n-1;j++){
if(ratou[j]>tarou[j+1]){
a=tarou[j];
tarou[j]=tarou[j+1];
tarou[j+1]=a;
}
}
}
j=0;
a=0;
for(i=0;i<n*2;i++){
if(tarou[j]!=i){
hanako[a]=i;
a++;
}
else if(tarou[j]==i)j++;
}
suu1=n;
suu2=n;
t=0;
ba=0;
while(suu2!=0&&suu1!=0){
if(t==0){
for(i=0;i<n;i++){
if(ba<tarou[i]&&tarou[i]!=0){
ba=tarou[i];
tarou[i]=0;
t=1;
suu2--;
break;
}
if(i==n-1){
t=1;
ba=0;
}
}
}
else if(t==1){
for(i=0;i<n;i++){
if(ba<hanako[i]&&hanako[i]!=0){
ba=hanako[i];
hanako[i]=0;
t=0;
suu1--;
break;
}
}
}
}
printf("%d\n%d\n",suu1,suu2);
}
return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:18:4: error: 'ratou' was not declared in this scope
   18 | if(ratou[j]>tarou[j+1]){
      |    ^~~~~
Language: C++

	hanako++;
      }
    }
    int field=0;
    int fieldO=-1;
    int point[2];
    point[0]=n; 
    point[1]=n;
    while(point[0]!=0 && point[1]!=0){
      for(int i=0;i<2;i++){
	for(int j=0;j<n;j++){
	  if(player[i][j]>field){
	    field=player[i][j];
	    player[i][j]=-1;
	    point[i]--;
	    fieldO=i;
	   
	    
	    break;
	  }
	 
	}
	if(fieldO==i*-1+1){
	  fieldO=i+10;
	  field=0;
	  break;
	}

      

      }
    }
    cout << point[1] << endl;
    cout << point[0] << endl;
  }
}

Compiler output:
a.cc:1:9: error: 'hanako' does not name a type
    1 |         hanako++;
      |         ^~~~~~
a.cc:2:7: error: expected declaration before '}' token
    2 |       }
      |       ^
a.cc:3:5: error: expected declaration before '}' token
    3 |     }
      |     ^
a.cc:7:5: error: 'point' does not name a type; did you mean 'int'?
    7 |     point[0]=n;
      |     ^~~~~
      |     int
a.cc:8:5: error: 'point' does not name a type; did you mean 'int'?
    8 |     point[1]=n;
      |     ^~~~~
      |     int
a.cc:9:5: error: expected unqualified-id before 'while'
    9 |     while(point[0]!=0 && point[1]!=0){
      |     ^~~~~
a.cc:33:5: error: 'cout' does not name a type
   33 |     cout << point[1] << endl;
      |     ^~~~
a.cc:34:5: error: 'cout' does not name a type
   34 |     cout << point[0] << endl;
      |     ^~~~
a.cc:35:3: error: expected declaration before '}' token
   35 |   }
      |   ^
a.cc:36:1: error: expected declaration before '}' token
   36 | }
      | ^
Language: C++

#include<iostream>

using namespace std;

int n, Taro, Hanako, i, x, turn, card[201], field;

int main(){


while(1){
	cin >> n;
if(!n){break;}
	Taro = n;
	Hanako = n;

	for(i=0;i<n;i++){
		cin >> x;
		card[x] = 1;
	}
	for(i=1;i<=2*n;i++){
		if(!card[i]){
			card[i] = 2;
		}
	}

	turn = 1;

	while(Taro>0 && Hanako>0){
		if(turn == 1){
			for(i=1;i<=2*n;i++){
				if(card[i]==1 && i > field){
					field = i;
					Taro--;
					turn = 2;
					card[i] = 0;
					break;
				}
				if(i==2*n){
					field = 0;
					turn = 2;
				}
			}
		}
		else if(turn == 2){
			for(i=1;i<=2*n;i++){
				if(card[i]==2 && i > field){
					field = i;
					Hanako--;
					turn = 1;
					card[i] = 0;
					break;
				}
				if(i==2*n){
					field = 0;
					turn = 1;
				}
			}
		}
	}

	if(!Taro){
		cout << Hanako << endl << 0 << endl;
	}
	else if(!Hanako){
		cout << 0 << endl << Taro << endl;
	}
　　　　}

	return 0;
}

Compiler output:
a.cc:67:1: error: extended character 　 is not valid in an identifier
   67 | 　　　　}
      | ^
a.cc:67:1: error: extended character 　 is not valid in an identifier
a.cc:67:1: error: extended character 　 is not valid in an identifier
a.cc:67:1: error: extended character 　 is not valid in an identifier
a.cc: In function 'int main()':
a.cc:67:1: error: '\U00003000\U00003000\U00003000\U00003000' was not declared in this scope
   67 | 　　　　}
      | ^~~~~~~~
Language: C

#include<stdio.h>
#include<mpi.h>
#include<stdlib.h>

int main(int argc, char *argv[])
{

  int nmax, rank, np, *p, *data, *result;
  int start, end, tag = 0;
  double t0, t1;
  MPI_Request req0, req1;
  MPI_Status stat;

  int m,n,i,j,temp,x1[205],y1[205],x2[1010],y2[1010],count,sum,k;
  int difx,dify,range;

  MPI_Init(&argc, &argv);
  MPI_Comm_size(MPI_COMM_WORLD, &np);
  MPI_Comm_rank(MPI_COMM_WORLD, &rank);

  while(1){

    if(rank == 0){
      
      scanf("%d",&m);
      
    }
    
    MPI_Bcast(&m, 1, MPI_INT, 0, MPI_COMM_WORLD);
     

    if(!m) break;
      
    if(rank == 0){
      
      for(i = 0; i < m; i++){
	scanf("%d %d",&x1[i],&y1[i]);
      }
      
      for(i = 0; i < m-1; i++){
	for(j = m-1; j > i; j--){
	  if(x1[j] < x1[j-1] || (x1[j] == x1[j-1] && y1[j] < y1[j-1])){
	    temp = x1[j];
	    x1[j] = x1[j-1];
	    x1[j-1] = temp;
	    temp = y1[j];
	    y1[j] = y1[j-1];
	    y1[j-1] = temp;
	  }
	}
      }
      
      scanf("%d",&n);

    }
      
    MPI_Bcast(&n, 1, MPI_INT, 0, MPI_COMM_WORLD);
    
    if(rank == 0){
      
      for(i = 0; i < n; i++){
	scanf("%d %d",&x2[i],&y2[i]);
      }
      
      
      for(i = 0; i < n-1; i++){
	for(j = n-1; j > i; j--){
	  if(x2[j] < x2[j-1] || (x2[j] == x2[j-1] && y2[j] < y2[j-1])){
	    temp = x2[j];
	    x2[j] = x2[j-1];
	    x2[j-1] = temp;
	    temp = y2[j];
	    y2[j] = y2[j-1];
	    y2[j-1] = temp;
	  }
	}
      }

    }

    MPI_Bcast(x1, m, MPI_INT, 0, MPI_COMM_WORLD);
    MPI_Bcast(y1, m, MPI_INT, 0, MPI_COMM_WORLD);
    MPI_Bcast(x2, n, MPI_INT, 0, MPI_COMM_WORLD);
    MPI_Bcast(y2, n, MPI_INT, 0, MPI_COMM_WORLD);
   

    start = m/np * rank;
    end = start + m/np;
    if(rank == np-1) end += m%np;    


    for(i = 0; i < n-m; i++){
      difx = x2[i]-x1[0];
      dify = y2[i]-y1[0];
 
      count = 0;	
      
      for(j = start; j < end; j++){
	for(k = i+1; k < n; k++){
	  if(x1[j] + difx == x2[k] && y1[j] + dify == y2[k]) count++;
	}
      }         


      MPI_Reduce(&count, &sum, 1, MPI_INT, MPI_SUM, 0, MPI_COMM_WORLD);
      
      MPI_Bcast(&sum, 1, MPI_INT, 0, MPI_COMM_WORLD);

      if(sum+1 == m) break;
      
    }
    
    if(rank == 0) printf("%d %d\n",difx,dify);
    
  }

  MPI_Finalize();
  
  return 0;
  
}

Compiler output:
main.c:2:9: fatal error: mpi.h: No such file or directory
    2 | #include<mpi.h>
      |         ^~~~~~~
compilation terminated.
Language: C

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

int main(void)
{

    int m, n;
    int *mx;
    mx = malloc(1000000);
    int *my;
    my = malloc(1000000);
    int *nx;
    nx = malloc(1000000);
    int *ny;
    ny = malloc(1000000);

    int mxmax = 0;
    int mymax = 0;
    int mxmin = 1000000;
    int mymin = 1000000;
    int nxmax = 0;
    int nymax = 0;
    int nxmin = 1000000;
    int nymin = 1000000;
    int xans;
    int yans;

    while (1)
    {
        scanf("%d", &m);
        if (m == 0)
            break;
        for (int i = 0; i < m; i++)
        {
            scanf("%d %d", &mx[i], &my[i]);
            if (mx[i] > mxmax)
                mxmax = mx[i];
            if (mxmin > mx[i])
                mxmin = mx[i];
            if (my[i] > mymax)
                mymax = my[i];
            if (mymin > my[i])
                mymin = my[i];
        }
        scanf("%d", &n);
        for (int j = 0; j < n; j++)
        {
            scanf("%d %d", &nx[j], &ny[j]);
            if (nx[j] > nxmax)
                nxmax = nx[j];
            if (nxmin > nx[j])
                nxmin = nx[j];
            if (ny[j] > nymax)
                nymax = ny[j];
            if (nymin > ny[j])
                nymin = ny[j]
        }

        /*       for (int k = nxmin - mxmin; k < nxmax - mxmax;k++)
        {
            for (int l = nymin - mymin; l < nymax - nymax;l++)
            {
                if ()
            }
        }
*/
        xans = nxmax - mxmax;
        yans = nymax - mymax;
        printf("%d %d\n", xans, yans);
    }

    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:58:30: error: expected ';' before '}' token
   58 |                 nymin = ny[j]
      |                              ^
      |                              ;
   59 |         }
      |         ~
Language: C

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

int x,y;
int sx[200],sy[200],gx[1000],gy[1000],m,n,ss;
void Ssort(){
	int a,b,c;
	for(a=0;a<m-1;a++){
		for(b=a;b<m;b++){
			if(sy[a]>sy[b]){
				c=sy[a];
				sy[a]=sy[b];
				sy[b]=c;
				c=sx[a];
				sx[a]=sx[b];
				sx[b]=c;
			}
			if(sy[a]==sy[b] && sx[a]>sx[b]){
				c=sy[a];
				sy[a]=sy[b];
				sy[b]=c;
				c=sx[a];
				sx[a]=sx[b];
				sx[b]=c;
			}
		}
	}
}
void Gsort(){
	int a,b,c;
	for(a=0;a<n-1;a++){
		for(b=a;b<n;b++){
			if(gy[a]>gy[b]){
				c=gy[a];
				gy[a]=gy[b];
				gy[b]=c;
				c=gx[a];
				gx[a]=gx[b];
				gx[b]=c;
			}
			if(gy[a]==gy[b] && gx[a]>gx[b]){
				c=gy[a];
				gy[a]=gy[b];
				gy[b]=c;
				c=gx[a];
				gx[a]=gx[b];
				gx[b]=c;
			}
		}
	}
}
bool Scheck(int k){
	int a;
	for(a=k;a<n;a++){
		if(sy[ss]<gy[a]-y){
			return 0;
		}
		if(sx[ss]+x==gx[a] && sy[ss]+y==gy[a]){
			ss++;
		}
		if(ss==m){
			return 1;
		}
	}
	return 0;
}
bool Seiza(){
	int a;
	for(a=0;a<n-m+1;a++){
		ss=1;
		x=gx[a]-sx[0];
		y=gy[a]-sy[0];
		if(Scheck(a)==1)return 1;
	}
	return 0;
	
}
int main(void){
	int a,b;
	while(1){
		scanf("%d",&m);
		if(m==0)break;
		for(a=0;a<m;a++){
			scanf("%d %d",&sx[a],&sy[a]);
		}
		Ssort();
		scanf("%d",&n);
		for(a=0;a<n;a++){
			scanf("%d %d",&gx[a],&gy[a]);
		}
		Gsort();
		if(Seiza()==1)printf("%d %d\n",x,y);else printf("-1\n");
	}
}

Compiler output:
main.c:52:1: error: unknown type name 'bool'
   52 | bool Scheck(int k){
      | ^~~~
main.c:3:1: note: 'bool' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'
    2 | #include <stdlib.h>
  +++ |+#include <stdbool.h>
    3 | 
main.c:67:1: error: unknown type name 'bool'
   67 | bool Seiza(){
      | ^~~~
main.c:67:1: note: 'bool' is defined in header '<stdbool.h>'; this is probably fixable by adding '#include <stdbool.h>'