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

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

int main() {
	vector<pair<int,int>> e(3);
 	for (auto& x : e) cin >> x.first >> x.second;
    sort(e.begin(), e.end());
	do {
    	if (e[0].second == e[1].first && e[1].second == e[2].first && e[0].first != e[2].second) {
          cout << "YES\n";
          return 0;
        }
    } while (next_permutation(e.begin(), e.end());
    cout << "NO\n";
}

Compiler output:
a.cc: In function 'int main()':
a.cc:13:50: error: expected ')' before ';' token
   13 |     } while (next_permutation(e.begin(), e.end());
      |             ~                                    ^
      |                                                  )
Language: C

#include<stdio.h>
int main()
{
  int a,b,c,d,e,f,g,h
    

Compiler output:
main.c: In function 'main':
main.c:4:3: error: expected '=', ',', ';', 'asm' or '__attribute__' at end of input
    4 |   int a,b,c,d,e,f,g,h
      |   ^~~
main.c:4:3: error: expected declaration or statement at end of input
Language: Java

import java.util.Scanner;

public class YahooBPath {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int[] nodes = new int[] {0,0,0,0};
		for(int i = 0; i < 3; i++) {
			int a = sc.nextInt();
			int b = sc.nextInt();
			nodes[a-1]++;
			nodes[b-1]++;
		}
		
		for(int i = 0; i < 3; i++) {
			if(nodes[i] < 0 || nodes[i] >= 3) {
				System.out.println("NO");
				return;
			}
		}
		
		System.out.println("YES");
	}

}


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

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

typedef long long int ll;
typedef unsigned int uint;
typedef unsigned char uchar;
typedef unsigned long long ull;
typedef pair<int, int> pii;
typedef pair<ll, ll> pll;
typedef vector<int> vi;
 
#define REP(i,x) for(int i=0;i<(int)(x);i++)
#define REPS(i,x) for(int i=1;i<=(int)(x);i++)
#define RREP(i,x) for(int i=((int)(x)-1);i>=0;i--)
#define RREPS(i,x) for(int i=((int)(x));i>0;i--)
#define FOR(i,c) for(__typeof((c).begin())i=(c).begin();i!=(c).end();i++)
#define RFOR(i,c) for(__typeof((c).rbegin())i=(c).rbegin();i!=(c).rend();i++)
#define ALL(container) (container).begin(), (container).end()
#define RALL(container) (container).rbegin(), (container).rend()
#define SZ(container) ((int)container.size())
#define mp(a,b) make_pair(a, b)
#define pb push_back
#define eb emplace_back
#define UNIQUE(v) v.erase( unique(v.begin(), v.end()), v.end() );

template <class T>
inline void in(T &m)
{
    char ch;
    int flag = 0;
    while ((ch = getchar()) < '0' || ch > '9')
    {
        if (ch == '-')
        {
            flag = 1;
        }
    }
    for (m = 0; ch >= '0' && ch <= '9'; ch = getchar())
    {
        m = m * 10 + ch - '0';
    }
    if (flag)
    {
        m *= -1;
    }
}

int main(){
    int path[4]={0};
     int a,b;
    SEP(i, 3) 
    {
      cin>>a>>b;
      path[a-1]++;
      path[b-1]++;
    }
    
  SEP(i, 3) 
   {
     if(path[i]>2){
     cout<<"NO"<<endl;
     return 0;}
  }
  
  cout<<"YES"<<endl;
    
return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:51:9: error: 'i' was not declared in this scope
   51 |     SEP(i, 3)
      |         ^
a.cc:51:5: error: 'SEP' was not declared in this scope; did you mean 'REP'?
   51 |     SEP(i, 3)
      |     ^~~
      |     REP
Language: C++

#include<iostream>
using namespace std;
int main() {
 int a[5]={0};
  
  int b;
  int i=1;
  while (i<7) {
    cin >> b;
    a[b]=a[b]+1;
    
    i=i+1
  }
  
  if (a[1]<3 && a[2]<3 && a[3]<3) cout << "YES";
  else cout << "NO";
  cout << endl;
  
  
  
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:10: error: expected ';' before '}' token
   12 |     i=i+1
      |          ^
      |          ;
   13 |   }
      |   ~
Language: C++

//答えを見てから書き直し
#include<iostream>
using namespace std;
int main() {
  int a[7],b,count[5];
  for (int i=1;i<7;i=i+1) a[i]=0;
  for (int i=1;i<6;i=i+1) count[i]=0;
  
  //出てくる数字を保存する
for (int j=1;j<7;j=j+1) cin >> a[i];
  
  //出てくる数字の回数を数える
  for (int i=1;i<5;i=i+1) {
    for (int j=1;j<7;j=j+1) {
  if (i==a[j]) count[i]=count[i]+1;
  
    }
  }
  
  //出てくる回数の最大値を求める
  int max;
  max=0;
  for (int i=1;i<5;i=i+1) {
    if (max<count[i]) max=count[i]; 
  }
  
  
  if (max<3) cout <<"YES";
  else cout <<"NO";
  cout << endl;
  
}


Compiler output:
a.cc: In function 'int main()':
a.cc:10:34: error: 'i' was not declared in this scope
   10 | for (int j=1;j<7;j=j+1) cin >> a[i];
      |                                  ^
Language: C++

//答えを見てから書き直し
include<iostream>
using namespace std;
int main() {
  int a[7],b,count[5];
  for (int i=1;i<7;i=i+1) a[i]=0;
  for (int i=1;i<6;i=i+1) count[i]=0;
  
  //出てくる数字を保存する
for (int j=1;j<7;j=j+1) cin >> a[i];
  
  //出てくる数字の回数を数える
  for (int i=1;i<5;i=i+1) {
    for (int j=1;j<7;j=j+1) {
  if (i==a[j]) count[i]=count[i]+1;
  
    }
  }
  
  //出てくる回数の最大値を求める
  int max;
  max=0;
  for (int i=1;i<5;i=i+1) {
    if (max<count[i]) max=count[i]; 
  }
  
  
  if (max<3) cout <<"YES";
  else cout <<"NO";
  cout << endl;
  
}

Compiler output:
a.cc:2:1: error: 'include' does not name a type
    2 | include<iostream>
      | ^~~~~~~
a.cc: In function 'int main()':
a.cc:10:25: error: 'cin' was not declared in this scope
   10 | for (int j=1;j<7;j=j+1) cin >> a[i];
      |                         ^~~
a.cc:10:34: error: 'i' was not declared in this scope
   10 | for (int j=1;j<7;j=j+1) cin >> a[i];
      |                                  ^
a.cc:28:14: error: 'cout' was not declared in this scope; did you mean 'count'?
   28 |   if (max<3) cout <<"YES";
      |              ^~~~
      |              count
a.cc:29:8: error: 'cout' was not declared in this scope; did you mean 'count'?
   29 |   else cout <<"NO";
      |        ^~~~
      |        count
a.cc:30:3: error: 'cout' was not declared in this scope; did you mean 'count'?
   30 |   cout << endl;
      |   ^~~~
      |   count
a.cc:30:11: error: 'endl' was not declared in this scope
   30 |   cout << endl;
      |           ^~~~
Language: C++

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

int main()
{
    int d[10];
    for(int i=0; i<= 4; i++) d[i] = 0;
    for(int i=0; i<6; i++)
    {
        int z;
        cin >> z;
        d[z]++;
    }
    if(d[1] <= 2 && d[2] <= 2 && d[3] <= 2 $$ d[4] <= 2) cout << "YES";
    else cout << "NO";
}

Compiler output:
a.cc: In function 'int main()':
a.cc:14:43: error: expected ')' before '$$'
   14 |     if(d[1] <= 2 && d[2] <= 2 && d[3] <= 2 $$ d[4] <= 2) cout << "YES";
      |       ~                                   ^~~
      |                                           )
Language: C++

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

int main()
{
    vector<int> vec(6);
    for(int i=0; i<6; i++)
    {
        cin >> vec[i];
    }

    map<int, int>;
    for(int i=0; i<6; i++)
    {
        map[vec[i]]++;
    }
    bool bl = true;
    
    for(int i=0; i<4; i++)
    {
        if(map[i] == 0) bl = false;
    }

    if(bl) cout << "YES";
    else cout << "NO";
}


Compiler output:
a.cc: In function 'int main()':
a.cc:12:5: error: declaration does not declare anything [-fpermissive]
   12 |     map<int, int>;
      |     ^~~~~~~~~~~~~
a.cc:15:16: error: expected ']' before '[' token
   15 |         map[vec[i]]++;
      |                ^
      |                ]
a.cc:15:20: error: expected initializer before '++' token
   15 |         map[vec[i]]++;
      |                    ^~
a.cc:15:20: error: expected ';' before '++' token
a.cc:21:15: error: expected unqualified-id before '[' token
   21 |         if(map[i] == 0) bl = false;
      |               ^
Language: C++

// g++ -std=c++11 a.cpp
#include<iostream>
#include<vector>
#include<string>
#include<algorithm>
#include<map>
#include<set>
#include<unordered_map>
#include<utility>
#include<cmath>
#include<random>
#include<cstring>
#include<queue>
#include<stack>
#include<bitset>
#include<cstdio>
#include<sstream>
#include<iomanip>
#include<assert.h>
#include<typeinfo>
#define loop(i,a,b) for(int i=a;i<b;i++)
#define rep(i,a) loop(i,0,a)
#define FOR(i,a) for(auto i:a)
#define pb push_back
#define all(in) in.begin(),in.end()
#define shosu(x) fixed<<setprecision(x)
#define show1d(v) {rep(_,v.size())cout<<" "<<v[_];puts("");}
#define show2d(v) {rep(__,v.size())show1d(v[__]);}
using namespace std;
//kaewasuretyuui
typedef long long ll;
#define int ll
typedef int Def;
typedef pair<Def,Def> pii;
typedef vector<Def> vi;
typedef vector<vi> vvi;
typedef vector<pii> vp;
typedef vector<vp> vvp;
typedef vector<string> vs;
typedef vector<double> vd;
typedef vector<vd> vvd;
typedef pair<Def,pii> pip;
typedef vector<pip>vip;
#define mt make_tuple
typedef tuple<int,int,int,int> tp;
typedef vector<tp> vt;
template<typename A,typename B>bool cmin(A &a,const B &b){return a>b?(a=b,true):false;}
template<typename A,typename B>bool cmax(A &a,const B &b){return a<b?(a=b,true):false;}
//template<class C>constexpr int size(const C &c){return (int)c.size();}
//template<class T,size_t N> constexpr int size(const T (&xs)[N])noexcept{return (int)N;}
const double PI=acos(-1);
const double EPS=1e-9;
Def inf = sizeof(Def) == sizeof(long long) ? 2e18 : 1e9+10;
// int dx[]={0,1,0,-1};
// int dy[]={1,0,-1,0};//RDLU
#define yes puts("YES")
#define no puts("NO")

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

	vi a(4);
	rep(i,6){
		int b;cin>>b;
		b--;a[b]++;
	}
	sort(all(a));
	vi c={1,1,2,2};
	if(a==b)yes;
	else no;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:70:15: error: 'b' was not declared in this scope
   70 |         if(a==b)yes;
      |               ^
Language: C

#include<stdio.h>
int a[6],hantei[4],flag;
int main(void){
    for(i = 0;i < 6;i++){
        scanf("%d",&a[i]);
    }
    for(i = 0;i < 6;i++){
        switch (a[i]){
            case 1:
            hantei[0] += 1;
            break;
            case 2:
            hantei[1] += 1;
            break;
            case 3:
            hantei[2] += 1;
            break;
            case 4:
            hantei[3] += 1;
            break;

        }
    }
    flag = 0;
    for(i = 0;i < 4;i++){
        if(hantei[i] >= 3){
            flag =1;
        }
    }
    if(flag == 0){
        printf("YES");
    }else{
        printf("NO");
    }
    return 0;
}

    

Compiler output:
main.c: In function 'main':
main.c:4:9: error: 'i' undeclared (first use in this function)
    4 |     for(i = 0;i < 6;i++){
      |         ^
main.c:4:9: note: each undeclared identifier is reported only once for each function it appears in
Language: C++

#include <iostream>
using namespace std;

int main(){
  int a[6];
  cin >> a[0]>>a[1]>>a[2]>>a[3]>>a[4]>>a[5];
  int b[4];
  for(int i=0; i < 6; i++){
    b[a[i]]++;
  }
  if(b[0]>0 && b[1]>0 && b[2]>0 && b[3]>0){
    cout << "YES" << endl;
  }else{
    cout << "NO" << endl;
}

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

#include<iostream>
using namespace std;
int main()
{
  int a[3],b[3];
  int i=0;
  while(i<3)
  {
    cin>>a[i]>>b[1]
  }
  int ans=0;
  if(a[0]==a[1]&&a[1]==a[2])
  {ans=1;}
  if(a[0]==a[1]&&a[1]==b[2])
  {ans=1;}
  if(a[0]==b[1]&&b[1]==a[2])
  {ans=1;}
  if(a[0]==b[1]&&b[1]==b[2])
  {ans=1;}
  if(b[0]==a[1]&&a[1]==a[2])
  {ans=1;}
  if(b[0]==a[1]&&a[1]==b[2])
  {ans=1;}
  if(b[0]==b[1]&&b[1]==a[2])
  {ans=1;}
  if(b[0]==b[1]&&b[1]==b[2])
  {ans=1;}
  if(ans==1)
  {cout<<"YES"<<endl;}
  else
  {cout<<"NO"<<endl;}
return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:20: error: expected ';' before '}' token
    9 |     cin>>a[i]>>b[1]
      |                    ^
      |                    ;
   10 |   }
      |   ~
Language: C++

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

int main(){
  int path[6];
  int buck[] = {0,0,0,0};
  
  for (int i=0;i<6;i++){
    cin >> path[i];
  }
  for (int i=0;i<6;i++){
    bucket[path[i]]++;
  }
  for(int i=0;i<4;i++){
    if(buck[i]>=3){
  cout << "NO" << endl;
  return 0;
    }
    }
  }
  cout << "YES" << endl;
  return 0;
}




Compiler output:
a.cc: In function 'int main()':
a.cc:13:5: error: 'bucket' was not declared in this scope; did you mean 'buck'?
   13 |     bucket[path[i]]++;
      |     ^~~~~~
      |     buck
a.cc: At global scope:
a.cc:22:3: error: 'cout' does not name a type
   22 |   cout << "YES" << endl;
      |   ^~~~
a.cc:23:3: error: expected unqualified-id before 'return'
   23 |   return 0;
      |   ^~~~~~
a.cc:24:1: error: expected declaration before '}' token
   24 | }
      | ^
Language: C++

#include <iostream>
using namespace std;

int main(){
	int a,i,c[5]={0,0,0,0},flag=0;
  	for(i=0;i<6;i++){
	cin>>a;
       for(int j=0;j<4;j++){
       	if(a==j){
		c[j]++;
        }
       }
      if(c[j]>2){
			flag=1;
           break;
         }
    }

  	if(flag==0){
		cout<<"YES"<<endl;
    }else{
		cout<<"NO"<<endl;
    }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:13:12: error: 'j' was not declared in this scope
   13 |       if(c[j]>2){
      |            ^
Language: C++

#include <iostream>
using namespace std;

int main(){
	int a,i,c[5]={0,0,0,0},flag=0;
  	for(i=0;i<6;i++){
	cin>>a;
       for(int j=0;j<4;j++){
       	if(a==j){
		c[j]++;
        }
         if(c[j]>2){
			flag=1;
           break;
         }
       }
    }

  	if(flag==0){
		cout<<YES<<endl;
    }else{
		cout<<NO<<endl;
    }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:20:23: error: 'YES' was not declared in this scope
   20 |                 cout<<YES<<endl;
      |                       ^~~
a.cc:22:23: error: 'NO' was not declared in this scope
   22 |                 cout<<NO<<endl;
      |                       ^~
Language: Java

import java.util.*;

public class Main {
    public static void main(String[] args) {
        List<Integer> list = new ArrayList<>();
        Scanner sc = new Scanner(System.in);
        for (int i = 0; i < 6; i++) {
            list.add(sc.nextInt());
        }

        boolean result = list.stream().collect(
                Collectors.groupingBy(x -> x, Collectors.counting())).entrySet().stream().noneMatch(x -> x.getValue() >= 3);
        System.out.print(result ? "YES" : "NO");
    }
}


Compiler output:
Main.java:12: error: cannot find symbol
                Collectors.groupingBy(x -> x, Collectors.counting())).entrySet().stream().noneMatch(x -> x.getValue() >= 3);
                ^
  symbol:   variable Collectors
  location: class Main
Main.java:12: error: cannot find symbol
                Collectors.groupingBy(x -> x, Collectors.counting())).entrySet().stream().noneMatch(x -> x.getValue() >= 3);
                                              ^
  symbol:   variable Collectors
  location: class Main
2 errors
Language: C++

#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
#define rep(i,n) for(int i=0;i<n;i++)

int main(){
    int a[4] = {0};
    int s, t;
    rep(i, 3){
        cin >> s >> t;
        a[s-1] += 1;
        a[t-1] += 1;
    }
    int odd = 0;
    rep(i, 4){
        if(a[i]%2==1) odd += 1;
    }
    if(odd==2 || odd==0) cout << "YES" << endl;
    else cout << "NO" << endl;
    return 0;

Compiler output:
a.cc: In function 'int main()':
a.cc:20:14: error: expected '}' at end of input
   20 |     return 0;
      |              ^
a.cc:6:11: note: to match this '{'
    6 | int main(){
      |           ^
Language: C

#include<stdio.h>
int main(void){
  int A[3],B[3],C[4],p=0,i;
  for(i=0;i<4;i++)C[i]=0;
  for(i=0;i<3;i++)scanf("%d%d",&A[i],&B[i]);
  for(i=0;i<3;i++){
    C[A[i]-1]++;
    C[B[i]-1]++;
  }
  for(i=0;i<4;i++){if(C[i]==0)p=-10;if(C[i]%2==1)p++;}
  if(p==0||p==2)printf("YES");
  else printf("NO");
} main(void){
  int A[3],B[3],C[4],p=0,i;
  for(i=0;i<4;i++)C[i]=0;
  for(i=0;i<3;i++)scanf("%d%d",&A[i],&B[i]);
  for(i=0;i<3;i++){
    C[A[i]-1]++;
    C[B[i]-1]++;
  }
  for(i=0;i<4;i++){if(C[i]==0)p=-10;if(C[i]%2==1)p++;}
  if(p==0||p==2)printf("YES");
  else printf("NO");
}


Compiler output:
main.c:13:3: error: return type defaults to 'int' [-Wimplicit-int]
   13 | } main(void){
      |   ^~~~
main.c:13:3: error: redefinition of 'main'
main.c:2:5: note: previous definition of 'main' with type 'int(void)'
    2 | int main(void){
      |     ^~~~
Language: C

#include<stdio.h>
intint main(void){
  int A[3],B[3],C[4],p=0,i;
  for(i=0;i<4;i++)C[i]=0;
  for(i=0;i<3;i++)scanf("%d%d",&A[i],&B[i]);
  for(i=0;i<3;i++){
    C[A[i]-1]++;
    C[B[i]-1]++;
  }
  for(i=0;i<4;i++){if(C[i]==0)p=-10;if(C[i]%2==1)p++;}
  if(p==0||p==2)printf("YES");
  else printf("NO");
} main(void){
  int A[3],B[3],C[4],p=0,i;
  for(i=0;i<4;i++)C[i]=0;
  for(i=0;i<3;i++)scanf("%d%d",&A[i],&B[i]);
  for(i=0;i<3;i++){
    C[A[i]-1]++;
    C[B[i]-1]++;
  }
  for(i=0;i<4;i++){if(C[i]==0)p=-10;if(C[i]%2==1)p++;}
  if(p==0||p==2)printf("YES");
  else printf("NO");
}

Compiler output:
main.c:2:1: error: unknown type name 'intint'
    2 | intint main(void){
      | ^~~~~~
main.c:13:3: error: return type defaults to 'int' [-Wimplicit-int]
   13 | } main(void){
      |   ^~~~
main.c:13:3: error: redefinition of 'main'
main.c:2:8: note: previous definition of 'main' with type 'int(void)'
    2 | intint main(void){
      |        ^~~~
Language: C++

#include <iostream>
#include <sstream>
#include <string>
#include <vector>
#include <list>
#include <stack>
#include <queue>
#include <set>
#include <map>
#include <bitset>
#include <algorithm>
#include <iterator>
#include <utility>
#include <iomanip>
#include <cmath>
#include <climits>
#include <cassert>
#include <stdio.h>
#include <string.h>

using namespace std;

void solve() {
  std::vector< std::vector<int> > vv(3, std::vector<int>(2));
  for (int _vi = 0; _vi < 3; _vi++) {
    for (int _vj = 0; _vj < 2; _vj++) {
      cin >> vv[_vi][_vj];
    }
  }
  
  std::vector<int> v(4, 0);
  for (auto tv : vv) {
    v[tv[0]]++;
    v[tv[1]]++;
  }
  
  auto odd_n = std::count_if( v.begin(), v.end(), [=](decltype(*begin(v)) x) -> bool {
      return ; x % 2 != 0;
    });
  bool ret = (odd_n == 2);

  std::cout << (ret ? "YES" : "NO") << std::endl;
}

int main(int argc, char *argv[])
{
  solve();
  return 0;
}


Compiler output:
a.cc: In lambda function:
a.cc:38:7: error: return-statement with no value, in function returning 'bool' [-fpermissive]
   38 |       return ; x % 2 != 0;
      |       ^~~~~~
Language: C++

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

int main(){
  int path[6];
  int buck[] = {0,0,0,0};
  string str = ;
  
  for (int i=0;i<6;i++){
    cin >> path[i];
    buck[path[i]]++;
  }
  for(int i=0;i<4;i++){
    if(buck[i]>=3){
  cout << "NO" << endl;
  return 0;
    }
    if(buck[i]==0){
  cout << "NO" << endl;
  return 0;
    }
  }
  cout << "YES" << endl;
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:16: error: expected primary-expression before ';' token
    8 |   string str = ;
      |                ^
Language: C++

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

int main(){
  int path[6];
  int buck[] = {0,0,0,0};
  string str = ;
  
  for (int i=0;i<6;i++){
    cin >> path[i];
    buck[path[i]]++;
  }
  for(int i=0;i<4;i++){
    if(buck[i]>=3){
  cout << "NO" << endl;
  return 0;
    }
  }
  cout << "YES" << endl;
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:16: error: expected primary-expression before ';' token
    8 |   string str = ;
      |                ^
Language: C++

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

int main(){
  int path[6];
  int buck[] = {0,0,0,0};
  string str = ;
  
  for (int i=0;i<6;i++){
    cin >> path[i];
    buck[path[i]]++;
  }
  for(int i=0;i<4;i++){
    if(buck[i]>=3){
  cout << "NO" << endl;
  return 0;
    }
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:16: error: expected primary-expression before ';' token
    8 |   string str = ;
      |                ^
Language: C++

#include<bits/stdc++.h>
using namespace         std;
#define                 int long long
#define                 pb push_back
#define                 mp make_pair
#define st(arr,a)       memset(arr,a,sizeof arr)
#define                 nl cout<<endl
#define                 real signed
#define                 endl '\n'              
#define bitcount(x)     __builtin_popcountll(x)
const int MOD = 1000000007ll;
#define forn(i,a,b)     for(int i=a;i<=b;i++)
#define rfor(i,a,b)     for(int i=a;i>=b;i--)
#define all(x)          x.begin() , x.end()
#define pi pair<int,int>
#define X first
#define Y second
#define N 314159


inline int mul(int a,int b){return (a*1ll*b)%MOD;}
inline int add(int a,int b){a+=b;if(a>=MOD)a-=MOD;return a;}
inline int power(int a,int b){int rt=1;while(b>0){if(b&1)rt=mul(rt,a);a=mul(a,a);b>>=1;}return rt;}
inline int inv(int a){return power(a,MOD-2);}


bitset<N>every;
int n,t;
int arr[N];
int freq[5];
signed main() 
{
     forn(i,1,3)
     {
          int a,b;
          cin>>a>>b;
          freq[a]++;
          freq[b]++;
     }
     sort(freq+1,freq+1+4);
     
     
          if(freq[1]==1 and freq[2]=1 and freq[3]==2 and freq[4]==2)
              cout<<"YES";
          else cout<<"NO";    
}

//       g++ -g c.cpp ; ./a.exe

Compiler output:
a.cc: In function 'int main()':
a.cc:43:25: error: lvalue required as left operand of assignment
   43 |           if(freq[1]==1 and freq[2]=1 and freq[3]==2 and freq[4]==2)
      |              ~~~~~~~~~~~^~~~~~~~~~~
Language: C++

#include <bits/stdc++.h>

int a[6], d[5];

int main(){
    scanf("%d%d%d%d%d%d", a, a + 1, a + 2, a + 3, a + 4, a + 5);
    for(int i = 0; i < 6; i++) d[a[i]]++;
    sort(d + 1, d + 5);
    int t = 1000 * d[1] + 100 * d[2] + 10 * d[3] + d[4];
    puts(t == 1122 ? "YES" : "NO");
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:5: error: 'sort' was not declared in this scope; did you mean 'std::sort'?
    8 |     sort(d + 1, d + 5);
      |     ^~~~
      |     std::sort
In file included from /usr/include/c++/14/algorithm:86,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 from a.cc:1:
/usr/include/c++/14/pstl/glue_algorithm_defs.h:296:1: note: 'std::sort' declared here
  296 | sort(_ExecutionPolicy&& __exec, _RandomAccessIterator __first, _RandomAccessIterator __last);
      | ^~~~
Language: C++

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

int main(){
  int a[6];
  for(int i=0;i<6;i++){
    cin >> a[i];
  }
  sort(a,a+6);
  int b[4];
  for(int i=0;i<4;i++){
    int b[i]=0;
  }
  for(int i=0;i<6;i++){
    for(int j=1;j<=4;j++){
      if(a[i]==j){
        b[j-1]++;
      }
    }
  }
  sort(b,b+4);
  if(b[3]>2){
    cout << "NO" << endl;
  }
  else{
    cout << "YES" << endl;
  }
}
        

Compiler output:
a.cc: In function 'int main()':
a.cc:13:14: error: array must be initialized with a brace-enclosed initializer
   13 |     int b[i]=0;
      |              ^
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main( )
{
    int arr[5];
    for(int i=0;i<4;i++)arr[i]=0;
    for(int i=0;i<6;i++){
        int x;
        cin>>x;
        arr[x]++;
    }
    if(arr[0]<=2 and
       arr[1]<=2 and
       arr[2]<=2 and
       arr[3]<=2 and){
        cout<<"YES\n";
    }
    else cout <<"NO\n";

}


Compiler output:
a.cc: In function 'int main()':
a.cc:15:21: error: expected primary-expression before ')' token
   15 |        arr[3]<=2 and){
      |                     ^
Language: C++

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

int main() {
	vector<int> p(3);
	vector<int> from(3), to(3);
	set<int> s;
	for (int i = 0; i < 3; ++i) {
		scanf("%d %d", &from[i], &to[i]);
		p[i] = i;
		s.insert(from[i]);
		s.insert(to[i]);
	}
	if (st.size() != 4) {
		puts("NO");
		return 0;
	}
	do {
		if (to[p[0]] == from[p[1]] && to[p[1]] == from[p[2]]) {
			puts("YES");
			return 0;
		}
	} while (next_permutation(p.begin(), p.end()));
	puts("NO");
}


Compiler output:
a.cc: In function 'int main()':
a.cc:14:13: error: 'st' was not declared in this scope; did you mean 's'?
   14 |         if (st.size() != 4) {
      |             ^~
      |             s
Language: C++

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

int main() {
	vector<int> p(3);
	vector<int> from(3), to(3);
	for (int i = 0; i < 3; ++i) {
		scanf("%d %d", &from[i], &to[i]);
		p[i] = i;
	}
	do {
		if (to[p[0]] == from[p[1]] && to[p[1]] == from[p[2]]) {
			puts("YES");
			return 0;
		}
	} while (next_permutation(p.begin(), p.end());
	puts("NO");
}

Compiler output:
a.cc: In function 'int main()':
a.cc:16:54: error: expected ')' before ';' token
   16 |         } while (next_permutation(p.begin(), p.end());
      |                 ~                                    ^
      |                                                      )
Language: C++

#include<iostream>
#include<algorithm>
using  namespace  std;
int  main (){
int  d [ 1 0 ] ;
f o r  ( int  i = 1;  i<= 4;  i++)d [ i ] = 0;
f o r  ( int  i = 0;  i<6;  i++){
int  z ;
scanf ("%d" , &z ) ;
d [ z]++;
}
i f  (d [ 1 ]<= 2 && d [ 2 ]<= 2 && d [ 3 ]<= 2 && d [ 4 ]<= 2) p r i n t f ("YESnn " ) ;
e l s e  p r i n t f ("NO\n " ) ;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:11: error: expected ']' before numeric constant
    5 | int  d [ 1 0 ] ;
      |           ^~
      |           ]
a.cc:6:1: error: 'f' was not declared in this scope
    6 | f o r  ( int  i = 1;  i<= 4;  i++)d [ i ] = 0;
      | ^
a.cc:6:23: error: 'i' was not declared in this scope
    6 | f o r  ( int  i = 1;  i<= 4;  i++)d [ i ] = 0;
      |                       ^
a.cc:7:2: error: expected ';' before 'o'
    7 | f o r  ( int  i = 0;  i<6;  i++){
      |  ^~
      |  ;
a.cc:12:2: error: expected ';' before 'f'
   12 | i f  (d [ 1 ]<= 2 && d [ 2 ]<= 2 && d [ 3 ]<= 2 && d [ 4 ]<= 2) p r i n t f ("YESnn " ) ;
      |  ^~
      |  ;
a.cc:13:1: error: 'e' was not declared in this scope
   13 | e l s e  p r i n t f ("NO\n " ) ;
      | ^
Language: C++

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

int main(void)
{
	vector<vector<bool>> ab(4, vector<bool>(4, false));
	for(int i=0; i<3; i++){
		int a, b;
		cin >> a >> b;

		a--;
		b--;

		ab[a][b] = true;
		ab[b][a] = true;
	}

	int odd, even;
	odd = even = 0;
	for(int i=0; i<4; i++){
		int cnt = count(ab[i].begin(), ab[i].end(), true);
		if(cnt%2 == 0)
			even++;
		else
			odd++;
	}

	if(odd == even)
		cout << "YES" << endl;
	else
		cout << "NO" << endl;

	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:24:27: error: 'count' was not declared in this scope; did you mean 'cnt'?
   24 |                 int cnt = count(ab[i].begin(), ab[i].end(), true);
      |                           ^~~~~
      |                           cnt
Language: C

#include <stdio.h>
int main(void){
    int N[6];
    int i,X,Y,f;
    int num[5]={0};
    int flag=0;
    
    for(i=0;i<6;i+=2){
    scanf("%d %d",&N[i],&N[i+1]);
    }
    for(i=0;i<6;i+=2){
    printf("%d %d ",N[i],N[i+1]);
    }
    
    for(i=0;i<6;i++){
        num[N[i]]+=1;    
    }
    for(i=1;i<5;i++){
    //printf("\n%d",num[i]);
        if(num[i]>2){
            flag+=1;
        }
    }
    
    if(flag==0){
        for(i=1;i<5;i++){
            if(num[i]==1){
                num[i]=0;
                X=i;
                break;
            }
        }
        for(i=1;i<5;i++){
            if(num[i]==1){
                Y=i;
                break;
            }
        }
        //printf("%d %d",X,Y);
    }
    
    for(i=0;i<6;i+=2){
        if(A[i]==X&&A[i+1]==Y){
            flag+=1;
        }
        else if(A[i]==Y&&A[i+1]==X){
            flag+=1;
        }
    }
    
    if(flag==0){
        printf("YES");
    }else{
        printf("NO");
    }
}


Compiler output:
main.c: In function 'main':
main.c:43:12: error: 'A' undeclared (first use in this function)
   43 |         if(A[i]==X&&A[i+1]==Y){
      |            ^
main.c:43:12: note: each undeclared identifier is reported only once for each function it appears in
Language: C++

#include <stdio.h>
int main(void){
    // Your code here!
    int path[6];
    scanf("%d %d", &path[0], &path[1]);
    scanf("%d %d", &path[2], &path[3]);
    scanf("%d %d", &path[4], &path[5]);
    int index = 0;
    for(int i = 2; i < 6; i++){
        if(path[0] == path[i]){
            index = i;
            break;
        }
    }
    if(index == 0){
        for(int i = 2; i < 6; i++){
            if(path[1] == path[i]){
                index = i;
                break;
            }
        }   
    }
    if(index == 0){
        printf("NO");
        exit(0);
    }else{
        if(index == 1 ||index == 3 ||index == 5){
            index--;
        }else{
            index++;
        }
        for(int i = 0; i < 6; i++){
            if(index == i){
                continue;
            }
            if(path[index] == path[i] && i != 0 && i != 1){
                printf("YES");
                exit(0);
            }
        }
    }
    printf("NO");
    exit(0);
}


Compiler output:
a.cc: In function 'int main()':
a.cc:25:9: error: 'exit' was not declared in this scope
   25 |         exit(0);
      |         ^~~~
a.cc:2:1: note: 'exit' is defined in header '<cstdlib>'; this is probably fixable by adding '#include <cstdlib>'
    1 | #include <stdio.h>
  +++ |+#include <cstdlib>
    2 | int main(void){
a.cc:38:17: error: 'exit' was not declared in this scope
   38 |                 exit(0);
      |                 ^~~~
a.cc:38:17: note: 'exit' is defined in header '<cstdlib>'; this is probably fixable by adding '#include <cstdlib>'
a.cc:43:5: error: 'exit' was not declared in this scope
   43 |     exit(0);
      |     ^~~~
a.cc:43:5: note: 'exit' is defined in header '<cstdlib>'; this is probably fixable by adding '#include <cstdlib>'
Language: C

#include<stdio.h>

int main(void)
{
int inp[6],i,j,temp;

for(i=0;i<6;i++)
{
    scanf("%d",&inp[i]);
}

for(i=0; i<6; i++)
{
    for(j=5; j>i; j--)
    {
      if(inp[j] < inp[j-1])
      {
        temp = N[j];
        N[j] = N[j-1];
        N[j-1] = temp;
      }
    }
  }


if(inp[0]==inp[1]==inp[2]&&inp[1]==inp[2]==inp[3]&&inp[2]==inp[3]==inp[4]&&inp[3]==inp[4]==inp[5]&&inp[4]==inp[5]==inp[6])
{
  printf("NO");
}
else
{
  printf("YES");
}
  return 0;
}


Compiler output:
main.c: In function 'main':
main.c:18:16: error: 'N' undeclared (first use in this function)
   18 |         temp = N[j];
      |                ^
main.c:18:16: note: each undeclared identifier is reported only once for each function it appears in
Language: C++

#include <algorithm>
#include <iostream>
#include <algorithm>
using namespace std;
int main(int argc, char const* argv[])
{
    int a1,b1,a2,b2,a3,b3;
  cin >> a1 >> b1 >> a2 >> b2 >> a3 >> b3;
  int i_array[] = {a1,a2,a3,b1,b1,b2,b3};
        sort(i_array, std::end(i_array),
                        [](int x, int y) -> int {
                        return ( x < y );
                        } );
        for (auto i: i_array) {
                i << " ";
        }
  if (i == 1 1 2 2 3 4 || i == 1 1 2 3 3 4 || i == 1 1 2 3 3 4 4 || i == 1 2 2 3 3 4 || i == 1 2 2 3 4 4 || i == 1 2 3 3 4 4){
        cout << "YES" << endl;
  }else{
    cout << "NO" << endl;
  }
        return 0;
}

Compiler output:
a.cc: In function 'int main(int, const char**)':
a.cc:15:19: error: invalid operands of types 'int' and 'const char [2]' to binary 'operator<<'
   15 |                 i << " ";
      |                 ~ ^~ ~~~
      |                 |    |
      |                 int  const char [2]
a.cc:17:7: error: 'i' was not declared in this scope
   17 |   if (i == 1 1 2 2 3 4 || i == 1 1 2 3 3 4 || i == 1 1 2 3 3 4 4 || i == 1 2 2 3 3 4 || i == 1 2 2 3 4 4 || i == 1 2 3 3 4 4){
      |       ^
a.cc:17:13: error: expected ')' before numeric constant
   17 |   if (i == 1 1 2 2 3 4 || i == 1 1 2 3 3 4 || i == 1 1 2 3 3 4 4 || i == 1 2 2 3 3 4 || i == 1 2 2 3 4 4 || i == 1 2 3 3 4 4){
      |      ~      ^~
      |             )
Language: C++

#include<iostream>
#include<vector>
#include<stack>
using namespace std;
static const int MAX = 100000;
static const int NIL = -1;

int n;
vector<int> G[MAX];
int color[MAX];

void dfs(int r, int c){
  stack<int>  S;
  S.push(r);
  color[r] = c;
  while (!S.empty()){
    int u = S.top();S.pop();
    for (int i=0; i<G[u].size(); i++){
      int v = G[u][i];
      if (color[v] == NIL){
        color[v] = c;
        S.push(v);
      }
    }
  }
}

void assignColor(){
  int id = 1;
  for (int i = 0; i<n; i++) color[i] = NIL;
  for (int u = 0; u<n; u++){
    if (color[u]==NIL) dfs(u, id++);
  }
}

int main(){
  int s, t, m, q;

  cin >> n >> m;

  for (int i=0; i<m; i++){
    cin >> s >> t;
    G[s].push_bask(t);
    G[t].push_bask(s);
  }
  assignColor();

  for (int i=0; i<4; i++){
    cin >> s >> t;
    if (color[s] == color[t]){
      cout << "YES" << endl;
    }
    else{
      cout << "NO" << endl;
    }
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:43:10: error: 'class std::vector<int>' has no member named 'push_bask'; did you mean 'push_back'?
   43 |     G[s].push_bask(t);
      |          ^~~~~~~~~
      |          push_back
a.cc:44:10: error: 'class std::vector<int>' has no member named 'push_bask'; did you mean 'push_back'?
   44 |     G[t].push_bask(s);
      |          ^~~~~~~~~
      |          push_back
Language: C++

#include<iostream>
#include<vector>
#include<stack>
using namespace std;
static const int MAX = 100000;
static const int NIL = -1;

int n;
vector<int> G[MAX];
int color[MAX];

void dfs(int r, int c){
  stack<int> = S;
  S.push(r);
  color[r] = c;
  while (!S.empty()){
    int u = S.top();S.pop();
    for (int i=0; i<G[u].size(); i++){
      int v = G[u][i];
      if (color[v] == NIL){
        color[v] = c;
        S.push(v);
      }
    }
  }
}

void assignColor(){
  int id = 1;
  for (int i = 0; i<n; i++) color[i] = NIL;
  for (int u = 0; u<n; u++){
    if (color[u]==NIL) dfs(u, id++)
  }
}

int main(){
  int s, t, m, q;

  cin >> n >> m;

  for (int i=0; i<m; i++){
    cin >> s >> t;
    G[s].push_bask(t);
    G[t].push_bask(s);
  }
  assignColor();

  for (int i=0; i<4; i++){
    cin >> s >> t;
    if (color[s] == color[t]){
      cout << "YES" << endl;
    }
    else{
      cout << "NO" << endl;
    }
  }
}


Compiler output:
a.cc: In function 'void dfs(int, int)':
a.cc:13:14: error: expected unqualified-id before '=' token
   13 |   stack<int> = S;
      |              ^
a.cc:14:3: error: 'S' was not declared in this scope
   14 |   S.push(r);
      |   ^
a.cc: In function 'void assignColor()':
a.cc:32:36: error: expected ';' before '}' token
   32 |     if (color[u]==NIL) dfs(u, id++)
      |                                    ^
      |                                    ;
   33 |   }
      |   ~                                 
a.cc: In function 'int main()':
a.cc:43:10: error: 'class std::vector<int>' has no member named 'push_bask'; did you mean 'push_back'?
   43 |     G[s].push_bask(t);
      |          ^~~~~~~~~
      |          push_back
a.cc:44:10: error: 'class std::vector<int>' has no member named 'push_bask'; did you mean 'push_back'?
   44 |     G[t].push_bask(s);
      |          ^~~~~~~~~
      |          push_back
Language: C++

#include<iostream>
#include<vector>
#include<stack>
using namespace std;
static const int MAX
static const int NIL = -1;

int n;
vector<int> G[MAX];
int color[MAX];

void dfs(int r, int c){
  stack<int> = S;
  S.push(r);
  color[r] = c;
  while (!S.empty()){
    int u = S.top();S.pop();
    for (int i=0; i<G[u].size(); i++){
      int v = G[u][i];
      if (color[v] == NIL){
        color[v] = c;
        S.push(v);
      }
    }
  }
}

void assignColor(){
  int id = 1;
  for (int i = 0; i<n; i++) color[i] = NIL;
  for (int u = 0; u<n; u++){
    if (color[u]==NIL) dfs(u, id++)
  }
}

int main(){
  int s, t, m, q;

  cin >> n >> m;

  for (int i=0; i<m; i++){
    cin >> s >> t;
    G[s].push_bask(t);
    G[t].push_bask(s);
  }
  assignColor();

  for (int i=0; i<4; i++){
    cin >> s >> t;
    if (color[s] == color[t]){
      cout << "YES" << endl;
    }
    else{
      cout << "NO" << endl;
    }
  }
}


Compiler output:
a.cc:6:1: error: expected initializer before 'static'
    6 | static const int NIL = -1;
      | ^~~~~~
a.cc:9:15: error: 'MAX' was not declared in this scope
    9 | vector<int> G[MAX];
      |               ^~~
a.cc:10:11: error: 'MAX' was not declared in this scope
   10 | int color[MAX];
      |           ^~~
a.cc: In function 'void dfs(int, int)':
a.cc:13:14: error: expected unqualified-id before '=' token
   13 |   stack<int> = S;
      |              ^
a.cc:14:3: error: 'S' was not declared in this scope
   14 |   S.push(r);
      |   ^
a.cc:15:3: error: 'color' was not declared in this scope; did you mean 'tolower'?
   15 |   color[r] = c;
      |   ^~~~~
      |   tolower
a.cc:18:21: error: 'G' was not declared in this scope
   18 |     for (int i=0; i<G[u].size(); i++){
      |                     ^
a.cc:20:23: error: 'NIL' was not declared in this scope
   20 |       if (color[v] == NIL){
      |                       ^~~
a.cc: In function 'void assignColor()':
a.cc:30:29: error: 'color' was not declared in this scope; did you mean 'tolower'?
   30 |   for (int i = 0; i<n; i++) color[i] = NIL;
      |                             ^~~~~
      |                             tolower
a.cc:30:40: error: 'NIL' was not declared in this scope
   30 |   for (int i = 0; i<n; i++) color[i] = NIL;
      |                                        ^~~
a.cc:32:9: error: 'color' was not declared in this scope; did you mean 'tolower'?
   32 |     if (color[u]==NIL) dfs(u, id++)
      |         ^~~~~
      |         tolower
a.cc:32:19: error: 'NIL' was not declared in this scope
   32 |     if (color[u]==NIL) dfs(u, id++)
      |                   ^~~
a.cc:32:36: error: expected ';' before '}' token
   32 |     if (color[u]==NIL) dfs(u, id++)
      |                                    ^
      |                                    ;
   33 |   }
      |   ~                                 
a.cc: In function 'int main()':
a.cc:43:5: error: 'G' was not declared in this scope
   43 |     G[s].push_bask(t);
      |     ^
a.cc:50:9: error: 'color' was not declared in this scope; did you mean 'tolower'?
   50 |     if (color[s] == color[t]){
      |         ^~~~~
      |         tolower
Language: C++

#include <iostream>
#include <vector>
#include <string>

int main(){
    std::vector<int> a(6);
    for (int i = 0; i < 6; i++){
      std::cin>>a[i];
    }

    std::sort(a.begin(),a.end());
    int sum = 0;
    for (int i = 0; i < 6; i++){
      if(a[i+1] - a[i] == 0){
        sum++;
      }else{
        sum = 0;
      }
      if(sum == 2){
        break;
      }
    }
    if(sum == 2){
      std::cout<<"NO"<<std::endl;
    }else{
      std::cout<<"YES"<<std::endl;
    }
    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:11:10: error: 'sort' is not a member of 'std'; did you mean 'qsort'?
   11 |     std::sort(a.begin(),a.end());
      |          ^~~~
      |          qsort
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main(){
	int a[6];
	int b=0,c=0,d=0,e=0;
	for(int i=0;i<a;i++){
		cin>>a[i];
		if(a[i]==1){
			b++;
		}
		else if(a[i]==2){
			c++;
		}
		else if(a[i]==3){
			d++;
		}
		else if(a[i]==4){
			e++;
		}
	}
	if(b==1&&c==1&&d==2&&e==2){
		cout<<"YES"<<endl;
	}
	else if(b==1&&c==2&&d==1&&e==2){
		cout<<"YES"<<endl;
	}
	else if(b==1&&c==2&&d==2&&e==1){
		cout<<"YES"<<endl;
	}
	else if(b==2&&c==1&&d==1&&e==2){
		cout<<"YES"<<endl;
	}
	else if(b==2&&c==1&&d==2&&e==1){
		cout<<"YES"<<endl;
	}
	else if(b==2&&c==2&&d==1&&e==1){
		cout<<"YES"<<endl;
	}
	else{
		cout<<"NO"<<endl;
	}
}


Compiler output:
a.cc: In function 'int main()':
a.cc:6:22: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
    6 |         for(int i=0;i<a;i++){
      |                     ~^~
Language: C++

#include<iostream>
#include<string>
#include<List>
using namespace std;


int main()
{
	int N = 3;
	int a[3];
	int b[3];
	bool F_NO = false;
	string rslt;

	for (int i = 0; i < N; i++) {
		std::cin >> a[i] >> b[i];
	}

	int baget[] = { 0,0,0,0 };
	for (int i = 0; i < N; i++) {
		if (a[i] == b[i])F_NO = true;
		baget[a[i]-1] += 1;
		baget[b[i]-1] += 1;
	}

	for (auto&& s : baget) {
		if (s < 1 || s>2)F_NO = true;
	}
	if (F_NO) {
		rslt = "NO";
	}
	else {
		rslt = "YES";
	}
	std::cout << rslt;


	return 0;

}

Compiler output:
a.cc:3:9: fatal error: List: No such file or directory
    3 | #include<List>
      |         ^~~~~~
compilation terminated.
Language: C++

#include<iostream>
#include<string>
#include<List>
using namespace std;


int main()
{
	int N = 3;
	int a[3];
	int b[3];
	bool F_NO = false;
	string rslt;

	for (int i = 0; i < N; i++) {
		std::cin >> a[i] >> b[i];
	}

	int baget[] = { 0,0,0,0 };
	for (int i = 0; i < N; i++) {
		if (a[i] == b[i])F_NO = true;
		baget[a[i]-1] += 1;
		baget[b[i]-1] += 1;
	}

	for (auto&& s : baget) {
		if (s < 1 || s>2)F_NO = true;
	}
        rslt = (F_NO)? "NO":"YES";

	std::cout << rslt;

	return 0;
}

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

import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.Arrays;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.ArrayList;
import java.util.Objects;
import java.util.List;
import java.util.StringTokenizer;
import java.io.BufferedReader;
import java.util.Collections;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 *
 * @author dyominov
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader in = new InputReader(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        BPath solver = new BPath();
        solver.solve(1, in, out);
        out.close();
    }

    static class BPath {
        public void solve(int testNumber, InputReader in, PrintWriter out) {
            List<A> list = new ArrayList<>();
            for (int i = 0; i < 3; i++) {
                int[] arr = new int[2];
                arr[0] = in.nextInt();
                arr[1] = in.nextInt();
                Arrays.sort(arr);
                list.add(new A(arr[0], arr[1]));
            }
            Collections.sort(list);
            int start = list.get(0).x;
            for (int j = 0; j < 1000; j++) {
                for (int i = 0; i < list.size(); i++) {
                    if (list.get(i).x == start || list.get(i).y == start) {
                        if (list.get(i).x == start) {
                            start = list.get(i).y;
                        } else {
                            start = list.get(i).x;
                        }
                        list.remove(i);
                        i--;
                    }
                }
            }
            out.println(list.isEmpty() ? "YES" : "NO");


        }

        class A implements Comparable<A> {
            int x;
            int y;

            A(int x, int y) {
                this.x = x;
                this.y = y;
            }

            public boolean equals(Object o) {


Compiler output:
Main.java:72: error: reached end of file while parsing
            public boolean equals(Object o) {
                                             ^
1 error
Language: C++

#include <bits/stdc++.h> 
using namespace std;
typedef long long ll;
typedef pair<ll,ll> p;
const int inf=(1<<30);
#define rep(i,a,n)	for(int i=a;i<n;i++)
#define rrep(i,a,n) for(int i=(a-1);i>=n;i--)
	
bool pairComparesecond(const p& firstElof, const p& secondElof)
{
    return firstElof.second > secondElof.second;
}
	ll a[5];
int main(){
	
	rep(i,0,3){
		ll f,t;
		cin>>f>>t;
		a[f--]++;
		a[t--]++;
	}
	rep(i,0,3){
		if(a[i]==3){
			cout<<"NO"<<endl;
			return;
		}
		else continue;
	}
	cout<<"YES"<<endl;
	
}

Compiler output:
a.cc: In function 'int main()':
a.cc:25:25: error: return-statement with no value, in function returning 'int' [-fpermissive]
   25 |                         return;
      |                         ^~~~~~
Language: C++

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

int main(){
  int a[3], b[3];
  int count[4] = {};
  for(int i < 0; i < 3; i++){
    cin >> a[i] >> b[i];
    count[a[i]-1]++;
    count[b[i]-1]++;
  }
  sort(count, count + 4);
  if(count[0] == 1 && count[1] == 1 && count[2] == 2 && count[3] == 2) cout << "YES" << endl;
  else cout << "NO" << endl;
  return 0;
}
    

Compiler output:
a.cc: In function 'int main()':
a.cc:8:12: error: expected ';' before '<' token
    8 |   for(int i < 0; i < 3; i++){
      |            ^~
      |            ;
a.cc:8:13: error: expected primary-expression before '<' token
    8 |   for(int i < 0; i < 3; i++){
      |             ^
a.cc:8:23: error: expected ')' before ';' token
    8 |   for(int i < 0; i < 3; i++){
      |      ~                ^
      |                       )
a.cc:8:25: error: 'i' was not declared in this scope
    8 |   for(int i < 0; i < 3; i++){
      |                         ^
Language: C++

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

int main() {
  	int a1,b1,a2,b2,a3,b3;
  cin >> a1 >> b1 >> a2 >> b2 >> a3 >> b3;
    int aiTable[6] = { a1, b1, a2, b2, a3, b3 };    // 配列を用意する。
    sort(aiTable, aiTable + 6);             // ソートする。
    {for (int iIndex = 0; iIndex < 6; iIndex++) {}}
     if(aiTable[iIndex]=={112234}||aiTable[iIndex]=={112334}||aiTable[iIndex]=={112344}||aiTable[iIndex]=={122334}||aiTable[iIndex]=={122344}||aiTable[iIndex]=={123344}){
    cout << "YES" << endl;
     }else{
       cout << "NO" << endl; 
     }
       return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:17: error: 'iIndex' was not declared in this scope
   11 |      if(aiTable[iIndex]=={112234}||aiTable[iIndex]=={112334}||aiTable[iIndex]=={112344}||aiTable[iIndex]=={122334}||aiTable[iIndex]=={122344}||aiTable[iIndex]=={123344}){
      |                 ^~~~~~
a.cc:11:26: error: expected primary-expression before '{' token
   11 |      if(aiTable[iIndex]=={112234}||aiTable[iIndex]=={112334}||aiTable[iIndex]=={112344}||aiTable[iIndex]=={122334}||aiTable[iIndex]=={122344}||aiTable[iIndex]=={123344}){
      |                          ^
a.cc:11:26: error: expected ')' before '{' token
   11 |      if(aiTable[iIndex]=={112234}||aiTable[iIndex]=={112334}||aiTable[iIndex]=={112344}||aiTable[iIndex]=={122334}||aiTable[iIndex]=={122344}||aiTable[iIndex]=={123344}){
      |        ~                 ^
      |                          )
Language: C

#include <stdio.h>
#include <stdbool.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
typedef long long int ll;
#define mod 1000000007
#define rep(i, n) for(int i = 0; i < (int)(n); i++)
#define m0(x) memset(x,0,sizeof(x))

int main(void)
{
	int a[3],b[3],count=0;
	rep(i,3) scanf("%d %d",&a[i],&b[i]);
	rep(i,3){
		count=0;
		rep(j,3){
			if(a[j]==i+1) count++;
			if(b[j]==i+1) count++;
		}
		if(count==3||count==0) break;
	}
	if(count==3||count==0) printf("NO\n");
	else printf("YES\n");


	return 0;
}.


Compiler output:
main.c:28:2: error: expected identifier or '(' before '.' token
   28 | }.
      |  ^
Language: C

#include <stdio.h>
int main(void){
    // Your code here!
    int N,i;
    int Ans[5]={1,2,2,3,3,4};
    for(f=0;f<6;f++){
    scanf("%d",&N);
    for(i=0;i<6;i++){
        if(Ans[i]==N){
         Ans[i]=0;   
        }
    }
    }
    if(Ans[0]==0&&Ans[1]==0&&Ans[2]==0&&Ans[3]==0&&Ans[4]==0&&Ans[5]==0){
        printf("YES");
    }else{
        printf("NO"):
    }
}


Compiler output:
main.c: In function 'main':
main.c:5:27: warning: excess elements in array initializer
    5 |     int Ans[5]={1,2,2,3,3,4};
      |                           ^
main.c:5:27: note: (near initialization for 'Ans')
main.c:6:9: error: 'f' undeclared (first use in this function)
    6 |     for(f=0;f<6;f++){
      |         ^
main.c:6:9: note: each undeclared identifier is reported only once for each function it appears in
main.c:17:21: error: expected ';' before ':' token
   17 |         printf("NO"):
      |                     ^
      |                     ;
Language: C

#include <stdio.h>
int main(void){
 
int a1,a2,a3,b1,b2,b3;

scanf("%d %d",&a1,&b1);
scanf("%d %d",&a2,&b2)
scanf("%d %d",&a3,&b3)

return 0;
 
}

Compiler output:
main.c: In function 'main':
main.c:7:23: error: expected ';' before 'scanf'
    7 | scanf("%d %d",&a2,&b2)
      |                       ^
      |                       ;
    8 | scanf("%d %d",&a3,&b3)
      | ~~~~~