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

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

int main(){
  string j;
  getline(cin, j);
  
  int a = 0;
  int b = 0;
  for(int i =0; i<4; i++){
    if(j[i] == 'A'){
      a++;
    }else{
		b++;
    }
  }
  if(sum == 3){
    cout << "No";
  }else{
    cout << "Yes";
  }
}

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

import java.util.Scanner;

public class main
{
    public static void main(String [] args)
    {
        Scanner key = new Scanner(System.in);
        String s = key.nextLine();
        int a = 0;
        int b = 0;

        for(int i = 0; i<s.length(); i++)
        {
            char c = s.charAt(i);
            if(c == 'A')
                a++;
            else
                b++;
        }

        if(a == 0 || b == 0)
        {
            System.out.println("No");
        }
        else
            System.out.println("Yes");
    }
}

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

#inculde <stdio.h>
int main(){
  char s;
  scanf("%s",&s);
  if(s=="AAA"||s=="BBB"){
    printf("No");
  }else{
    printf("Yes")
  }
  
  return 0;
}

Compiler output:
main.c:1:2: error: invalid preprocessing directive #inculde; did you mean #include?
    1 | #inculde <stdio.h>
      |  ^~~~~~~
      |  include
main.c: In function 'main':
main.c:4:3: error: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
    4 |   scanf("%s",&s);
      |   ^~~~~
main.c:1:1: note: include '<stdio.h>' or provide a declaration of 'scanf'
  +++ |+#include <stdio.h>
    1 | #inculde <stdio.h>
main.c:4:3: warning: incompatible implicit declaration of built-in function 'scanf' [-Wbuiltin-declaration-mismatch]
    4 |   scanf("%s",&s);
      |   ^~~~~
main.c:4:3: note: include '<stdio.h>' or provide a declaration of 'scanf'
main.c:5:7: warning: comparison between pointer and integer
    5 |   if(s=="AAA"||s=="BBB"){
      |       ^~
main.c:5:17: warning: comparison between pointer and integer
    5 |   if(s=="AAA"||s=="BBB"){
      |                 ^~
main.c:6:5: error: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
    6 |     printf("No");
      |     ^~~~~~
main.c:6:5: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:6:5: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
main.c:6:5: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:8:5: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
    8 |     printf("Yes")
      |     ^~~~~~
main.c:8:5: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:8:18: error: expected ';' before '}' token
    8 |     printf("Yes")
      |                  ^
      |                  ;
    9 |   }
      |   ~
Language: C++

s = input()
if s.count('A') >= 1 and s.count('B') >= 1:
    print('Yes')
else:
    print('No')


Compiler output:
a.cc:3:11: warning: multi-character character constant [-Wmultichar]
    3 |     print('Yes')
      |           ^~~~~
a.cc:5:11: warning: multi-character character constant [-Wmultichar]
    5 |     print('No')
      |           ^~~~
a.cc:1:1: error: 's' does not name a type
    1 | s = input()
      | ^
Language: C

#include<stdio.h>
{
	char s[2];
	scanf("%s", s);
	if (s[0] == s[1] && s[1] == s[2]) {
		printf("No");
	} else {
		printf("Yes");
	}
	return 0;
}

Compiler output:
main.c:2:1: error: expected identifier or '(' before '{' token
    2 | {
      | ^
Language: C++

#include <bits/stdc++.h>
 
using namespace std;
 
#define xx         first
#define yy         second
#define pb         push_back
#define mp         make_pair
#define LL         long long
#define inf        INT_MAX/3
#define mod        1000000007ll
#define PI         acos(-1.0)
#define linf       (1ll<<60)-1
#define FOR(I,A,B) for(int I = (A); I < (B); ++I)
#define REP(I,N)   FOR(I,0,N)
#define For(I,N)   for(int I=1;I<=(N);I++)
#define ALL(A)     ((A).begin(), (A).end())
#define set0(ar)   memset(ar,0,sizeof ar)
#define vsort(v)   sort(v.begin(),v.end())
#define setinf(ar) memset(ar,126,sizeof ar)
#define SZ(X) ((int)(X.size()))
#define LG(X) ((int)(X.length()))
#define CL(X) (X).clear()
#define MAXEL(A,B) (*max_element(A,B))
#define MINEL(A,B) (*min_element(A,B))
#define ROPEN(X) freopen(X,"r",stdin)
#define WOPEN(X) freopen(X,"w",stdout)
#define BG(X) (X.begin())
#define EN(X) (X.end())
#define VI vector<int>
#define PII pair<int,int>
 
//cout << fixed << setprecision(20) << p << endl;
 
template <class T> inline T bigmod(T p,T e,T M){
    LL ret = 1;
    for(; e > 0; e >>= 1){
        if(e & 1) ret = (ret * p) % M;
        p = (p * p) % M;
    } return (T)ret;
}
template <class T> inline T gcd(T a,T b){if(b==0)return a;return gcd(b,a%b);}
template <class T> inline T modinverse(T a,T M){return bigmod(a,M-2,M);}


int main(){
	ios_base::sync_with_stdio(false);
    cin.tie(NULL);
	int a,b;
	cin>>a>>b;
	for(int i=1;i<=100;i++){
		    if (i * 8/100 == a && i * 10/100 == b) {
            cout << i << endl;
            return 0;
        }
	}	
	else{
		cout<<-1<<endl;
	}
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:57:9: error: 'else' without a previous 'if'
   57 |         else{
      |         ^~~~
Language: C++

#include <bits/stdc++.h>
 
using namespace std;
 
#define xx         first
#define yy         second
#define pb         push_back
#define mp         make_pair
#define LL         long long
#define inf        INT_MAX/3
#define mod        1000000007ll
#define PI         acos(-1.0)
#define linf       (1ll<<60)-1
#define FOR(I,A,B) for(int I = (A); I < (B); ++I)
#define REP(I,N)   FOR(I,0,N)
#define For(I,N)   for(int I=1;I<=(N);I++)
#define ALL(A)     ((A).begin(), (A).end())
#define set0(ar)   memset(ar,0,sizeof ar)
#define vsort(v)   sort(v.begin(),v.end())
#define setinf(ar) memset(ar,126,sizeof ar)
#define SZ(X) ((int)(X.size()))
#define LG(X) ((int)(X.length()))
#define CL(X) (X).clear()
#define MAXEL(A,B) (*max_element(A,B))
#define MINEL(A,B) (*min_element(A,B))
#define ROPEN(X) freopen(X,"r",stdin)
#define WOPEN(X) freopen(X,"w",stdout)
#define BG(X) (X.begin())
#define EN(X) (X.end())
#define VI vector<int>
#define PII pair<int,int>
 
//cout << fixed << setprecision(20) << p << endl;
 
template <class T> inline T bigmod(T p,T e,T M){
    LL ret = 1;
    for(; e > 0; e >>= 1){
        if(e & 1) ret = (ret * p) % M;
        p = (p * p) % M;
    } return (T)ret;
}
template <class T> inline T gcd(T a,T b){if(b==0)return a;return gcd(b,a%b);}
template <class T> inline T modinverse(T a,T M){return bigmod(a,M-2,M);}


int main(){
	ios_base::sync_with_stdio(false);
    cin.tie(NULL);
	int a,b;
	cin>>a>>b;
	for(int i=1;i<=100;i++){
		    if (i * 8/100 == a && i * 10/100 == b) {
            cout << i << endl;
            return 0;
        }
	}	
	else{
		cout<<'-1'<<endl;
	}
	return 0;
}


Compiler output:
a.cc:58:23: warning: multi-character character constant [-Wmultichar]
   58 |                 cout<<'-1'<<endl;
      |                       ^~~~
a.cc: In function 'int main()':
a.cc:57:9: error: 'else' without a previous 'if'
   57 |         else{
      |         ^~~~
Language: C++

#include <cstdio>
#include <type_traits>

int main() {
  static_assert(std::is_same<long, long long>::value, "");

  char s[4];
  scanf("%s", s);
  puts(((s[0]+s[1]+s[2]) % 3 == 0)? "No": "Yes");
}


Compiler output:
a.cc: In function 'int main()':
a.cc:5:48: error: static assertion failed
    5 |   static_assert(std::is_same<long, long long>::value, "");
      |                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~
Language: C++

#include <bits/stdc++.h>

using namespace std;
typedef long long ll;
typedef vector<ll> vl ;
typedef vector<int> vi;
typedef pair<int, int> pi;
typedef pair<ll,ll> pl;

#define rep(i,N) for(int i=0; i < (int)N; i++)
#define all(v) (v).begin(),(v).end()

const int INF = 100000002;

int main(){
	int s; cin >> s;
	if (s == "AAA" || s == "BBB") cout << "No" << endl;
	else cout << "Yes" << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:17:15: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   17 |         if (s == "AAA" || s == "BBB") cout << "No" << endl;
      |             ~~^~~~~~~~
a.cc:17:29: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
   17 |         if (s == "AAA" || s == "BBB") cout << "No" << endl;
      |                           ~~^~~~~~~~
Language: C++

#include <bits/stdc++.h>

using namespace std;

int main()
{
    string s;
    cin>>s;
    if (s[0]==s[1] && a[0]==s[2])
        cout<<"No";
    else
        cout<<"Yes";
    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:9:23: error: 'a' was not declared in this scope
    9 |     if (s[0]==s[1] && a[0]==s[2])
      |                       ^
Language: C++

#include <iostream>
using namespace std;

int main() {
	string s;
	cin>>s;
	
	if(s="AAA"||s="BBB")cout<<"Yes"<<endl;
	else cout<<"No"<<endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:19: error: no match for 'operator||' (operand types are 'const char [4]' and 'std::string' {aka 'std::__cxx11::basic_string<char>'})
    8 |         if(s="AAA"||s="BBB")cout<<"Yes"<<endl;
      |              ~~~~~^~~
      |              |      |
      |              |      std::string {aka std::__cxx11::basic_string<char>}
      |              const char [4]
a.cc:8:19: note: candidate: 'operator||(bool, bool)' (built-in)
    8 |         if(s="AAA"||s="BBB")cout<<"Yes"<<endl;
      |              ~~~~~^~~
a.cc:8:19: note:   no known conversion for argument 2 from 'std::string' {aka 'std::__cxx11::basic_string<char>'} to 'bool'
Language: C++

#include bitsstdc++.h
using namespace std;
 
int main() {
  
  vector <string> a(3);
  for(int i=0; i<3; i++){
    cin >> a.at(i);
  }
  
  if ((a.at(0) == a.at(1)) && (a.at(2) == a.at(1))){
    cout << "No" << endl;
  }
  
  else{
    cout << "Yes" << endl;
  }
}

Compiler output:
a.cc:1:10: error: #include expects "FILENAME" or <FILENAME>
    1 | #include bitsstdc++.h
      |          ^~~~~~~~
a.cc: In function 'int main()':
a.cc:6:3: error: 'vector' was not declared in this scope
    6 |   vector <string> a(3);
      |   ^~~~~~
a.cc:1:1: note: 'std::vector' is defined in header '<vector>'; this is probably fixable by adding '#include <vector>'
  +++ |+#include <vector>
    1 | #include bitsstdc++.h
a.cc:6:11: error: 'string' was not declared in this scope
    6 |   vector <string> a(3);
      |           ^~~~~~
a.cc:1:1: note: 'std::string' is defined in header '<string>'; this is probably fixable by adding '#include <string>'
  +++ |+#include <string>
    1 | #include bitsstdc++.h
a.cc:6:19: error: 'a' was not declared in this scope
    6 |   vector <string> a(3);
      |                   ^
a.cc:8:5: error: 'cin' was not declared in this scope
    8 |     cin >> a.at(i);
      |     ^~~
a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
  +++ |+#include <iostream>
    1 | #include bitsstdc++.h
a.cc:12:5: error: 'cout' was not declared in this scope
   12 |     cout << "No" << endl;
      |     ^~~~
a.cc:12:5: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:12:21: error: 'endl' was not declared in this scope
   12 |     cout << "No" << endl;
      |                     ^~~~
a.cc:1:1: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
  +++ |+#include <ostream>
    1 | #include bitsstdc++.h
a.cc:16:5: error: 'cout' was not declared in this scope
   16 |     cout << "Yes" << endl;
      |     ^~~~
a.cc:16:5: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:16:22: error: 'endl' was not declared in this scope
   16 |     cout << "Yes" << endl;
      |                      ^~~~
a.cc:16:22: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
Language: C++

#include bitsstdc++.h
using namespace std;
 
int main() {
  
  vector <int> a(3);
  for(int i=0; i<3; i++){
    cin >> a.at(i);
  }
  
  if ((a.at(0) == a.at(1)) && (a.at(2) == a.at(1))){
    cout << "No" << endl;
  }
  
  else{
    cout << "Yes" << endl;
  }
}


Compiler output:
a.cc:1:10: error: #include expects "FILENAME" or <FILENAME>
    1 | #include bitsstdc++.h
      |          ^~~~~~~~
a.cc: In function 'int main()':
a.cc:6:3: error: 'vector' was not declared in this scope
    6 |   vector <int> a(3);
      |   ^~~~~~
a.cc:1:1: note: 'std::vector' is defined in header '<vector>'; this is probably fixable by adding '#include <vector>'
  +++ |+#include <vector>
    1 | #include bitsstdc++.h
a.cc:6:11: error: expected primary-expression before 'int'
    6 |   vector <int> a(3);
      |           ^~~
a.cc:8:5: error: 'cin' was not declared in this scope
    8 |     cin >> a.at(i);
      |     ^~~
a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
  +++ |+#include <iostream>
    1 | #include bitsstdc++.h
a.cc:8:12: error: 'a' was not declared in this scope
    8 |     cin >> a.at(i);
      |            ^
a.cc:11:8: error: 'a' was not declared in this scope
   11 |   if ((a.at(0) == a.at(1)) && (a.at(2) == a.at(1))){
      |        ^
a.cc:12:5: error: 'cout' was not declared in this scope
   12 |     cout << "No" << endl;
      |     ^~~~
a.cc:12:5: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:12:21: error: 'endl' was not declared in this scope
   12 |     cout << "No" << endl;
      |                     ^~~~
a.cc:1:1: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
  +++ |+#include <ostream>
    1 | #include bitsstdc++.h
a.cc:16:5: error: 'cout' was not declared in this scope
   16 |     cout << "Yes" << endl;
      |     ^~~~
a.cc:16:5: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:16:22: error: 'endl' was not declared in this scope
   16 |     cout << "Yes" << endl;
      |                      ^~~~
a.cc:16:22: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
Language: C++

#include <iostream>
#include <string>
using namespace std;
int main(){
  char ser[3];
  cin >> ser;
  int A,B,i;
  for (i=1;i<=3;i++){
    if (ser[i]=='B'){
      B+=1}
    else {A+=1}}
  if (A!=0 && B !=0){
    cout << "Yes";}
  else cout << "No";}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:11: error: expected ';' before '}' token
   10 |       B+=1}
      |           ^
      |           ;
a.cc:11:15: error: expected ';' before '}' token
   11 |     else {A+=1}}
      |               ^
      |               ;
Language: C


  S = gets.chomp
  if S == "AAA" || S == "BBB"
    puts "No"
  else
    puts "Yes"
  return
end

Compiler output:
main.c:2:3: warning: data definition has no type or storage class
    2 |   S = gets.chomp
      |   ^
main.c:2:3: error: type defaults to 'int' in declaration of 'S' [-Wimplicit-int]
main.c:2:7: error: 'gets' undeclared here (not in a function)
    2 |   S = gets.chomp
      |       ^~~~
main.c:3:3: error: expected ',' or ';' before 'if'
    3 |   if S == "AAA" || S == "BBB"
      |   ^~
Language: C++

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

 int main(){
  string s;
   cin >> s;
   if(s[0] == s[1] && s[1] == s[2]){
     cout << "No" << endl;
   }
   else{
     cout << "Yes" << endl
   }
   
 }

Compiler output:
a.cc: In function 'int main()':
a.cc:11:27: error: expected ';' before '}' token
   11 |      cout << "Yes" << endl
      |                           ^
      |                           ;
   12 |    }
      |    ~
Language: Java

import java.util.*;
class Main{
    public static void main(String[] args){
	Scanner stdIn = new Scanner(System.in);
        String S = stdIn.next();
	if(S.equals(AAA)||S.equals(BBB)){
	    System.out.println("No");
	}else{
	    System.out.println("Yes");
	}
    }
}
	


Compiler output:
Main.java:6: error: cannot find symbol
	if(S.equals(AAA)||S.equals(BBB)){
	            ^
  symbol:   variable AAA
  location: class Main
Main.java:6: error: cannot find symbol
	if(S.equals(AAA)||S.equals(BBB)){
	                           ^
  symbol:   variable BBB
  location: class Main
2 errors
Language: C++

#include <iostream>
using namespce std;

int main(){
  string s;
  cin >> s;
  if(s == "AAA" or s == "BBB"){
    cout << "No" << endl;
  }
  else{
    cout << "Yes" << endl;
  }
  return 0;
}

Compiler output:
a.cc:2:7: error: expected nested-name-specifier before 'namespce'
    2 | using namespce std;
      |       ^~~~~~~~
a.cc: In function 'int main()':
a.cc:5:3: error: 'string' was not declared in this scope
    5 |   string s;
      |   ^~~~~~
a.cc:5:3: note: suggested alternatives:
In file included from /usr/include/c++/14/iosfwd:41,
                 from /usr/include/c++/14/ios:40,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/bits/stringfwd.h:77:33: note:   'std::string'
   77 |   typedef basic_string<char>    string;
      |                                 ^~~~~~
In file included from /usr/include/c++/14/bits/locale_classes.h:40,
                 from /usr/include/c++/14/bits/ios_base.h:41,
                 from /usr/include/c++/14/ios:44:
/usr/include/c++/14/string:76:11: note:   'std::pmr::string'
   76 |     using string    = basic_string<char>;
      |           ^~~~~~
a.cc:6:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    6 |   cin >> s;
      |   ^~~
      |   std::cin
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:6:10: error: 's' was not declared in this scope
    6 |   cin >> s;
      |          ^
a.cc:8:5: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    8 |     cout << "No" << 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:8:21: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
    8 |     cout << "No" << endl;
      |                     ^~~~
      |                     std::endl
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
a.cc:11:5: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   11 |     cout << "Yes" << 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:11:22: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   11 |     cout << "Yes" << endl;
      |                      ^~~~
      |                      std::endl
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
int main(){
  string s;
  cin >> s;
  
  if(s=="AAA" || s=="BBB"){
    cout << "No"
  }
  else{
    cout << "Yes";
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:17: error: expected ';' before '}' token
    9 |     cout << "No"
      |                 ^
      |                 ;
   10 |   }
      |   ~
Language: C++

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

int main(){
    string S; cin >> S;
    if(S.at(0)==S.at(1) && S.at(1)==S.at(2)){
        cout << 'No' << endl;
    }else{
        cout << "Yes" << endl;
    }
}*
/*int main(){
    string S;
    cin >> S;

}*/

Compiler output:
a.cc:7:17: warning: multi-character character constant [-Wmultichar]
    7 |         cout << 'No' << endl;
      |                 ^~~~
a.cc:11:3: error: expected unqualified-id at end of input
   11 | }*
      |   ^
Language: C++

#include "bits/stdc++.h"
using namespace std;
typedef long long ll;
typedef pair<int, int> pii;
typedef pair<ll, ll> pll;
const int INF = 1e9;
const ll LINF = 1e18;
inline ll gcd(ll a, ll b) { return b ? gcd(b, a%b) : a; }
inline ll lcm(ll a, ll b) { return a / gcd(a, b)*b; }
template<class S,class T> ostream& operator << (ostream& out,const pair<S,T>& o){ out << "(" << o.first << "," << o.second << ")"; return out; }
template<class T> ostream& operator << (ostream& out,const vector<T>& V){ for(int i = 0; i < V.size(); i++){ out << V[i]; if(i!=V.size()-1) out << " ";} return out; }
template<class T> ostream& operator << (ostream& out,const vector<vector<T> >& Mat){ for(int i = 0; i < Mat.size(); i++) { if(i != 0) out << endl; out << Mat[i];} return out; }
template<class S,class T> ostream& operator << (ostream& out,const map<S,T>& mp){ out << "{ "; for(auto it = mp.begin(); it != mp.end(); it++){ out << it->first << ":" << it->second; if(mp.size()-1 != distance(mp.begin(),it)) out << ", "; } out << " }"; return out; }
template<typename T>vector<T> make_v(size_t a){return vector<T>(a);}
template<typename T,typename... Ts>auto make_v(size_t a,Ts... ts){return vector<decltype(make_v<T>(ts...))>(a,make_v<T>(ts...));}
template<typename T,typename V> typename enable_if<is_class<T>::value==0>::type fill_v(T &t,const V &v){t=v;}
template<typename T,typename V> typename enable_if<is_class<T>::value!=0>::type fill_v(T &t,const V &v){for(auto &e:t) fill_v(e,v);}
/*
 <url:https://atcoder.jp/contests/abc158/tasks/abc158_a>
 問題文============================================================
 A - Station and Bus
 =================================================================
 解説=============================================================
 
 
 ================================================================
 */

template<class Type>
Type solve(Type res = Type()){
    string S;cin >> S;
    if(count(S.begin(),S.end(),'A') != 0) return "Yes";
    else return "No";
    
    return res;
}
int main(void) {
    cin.tie(0); ios_base::sync_with_stdio(false);
    // solve(0);
    cout << fixed << setprecision(15) << solve<ll>() << endl;
    return 0;
}


Compiler output:
a.cc: In instantiation of 'Type solve(Type) [with Type = long long int]':
a.cc:40:51:   required from here
   40 |     cout << fixed << setprecision(15) << solve<ll>() << endl;
      |                                          ~~~~~~~~~^~
a.cc:32:50: error: invalid conversion from 'const char*' to 'long long int' [-fpermissive]
   32 |     if(count(S.begin(),S.end(),'A') != 0) return "Yes";
      |                                                  ^~~~~
      |                                                  |
      |                                                  const char*
a.cc:33:17: error: invalid conversion from 'const char*' to 'long long int' [-fpermissive]
   33 |     else return "No";
      |                 ^~~~
      |                 |
      |                 const char*
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main(){
char S;
  cin>>S;
  if(S[0]==S[1]||S[1]==S[2]){
  cout<<"No"<<endl;
  
  }else{
  cout<<"Yes"<<endl;
  
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:6:7: error: invalid types 'char[int]' for array subscript
    6 |   if(S[0]==S[1]||S[1]==S[2]){
      |       ^
a.cc:6:13: error: invalid types 'char[int]' for array subscript
    6 |   if(S[0]==S[1]||S[1]==S[2]){
      |             ^
a.cc:6:19: error: invalid types 'char[int]' for array subscript
    6 |   if(S[0]==S[1]||S[1]==S[2]){
      |                   ^
a.cc:6:25: error: invalid types 'char[int]' for array subscript
    6 |   if(S[0]==S[1]||S[1]==S[2]){
      |                         ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main(){
string S;
  cin>>S;
  if(S[1]=="A"||S[1]=="B"){
  cout<<"Yes"<<endl;
  
  }else{
  cout<<"No"<<endl;
  
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:10: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
    6 |   if(S[1]=="A"||S[1]=="B"){
a.cc:6:21: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
    6 |   if(S[1]=="A"||S[1]=="B"){
Language: C++

#include <bits/stdc++.h>
using namespace std;
#define ar array
#define ll long long 
#define inf 0x3f3f3f3f
#define infll 0x3f3f3f3f3f3f3f3f
#define all(x) (x).begin(),(x).end()
#define f(i, a, b) for (int i=a; i<(signed)(b); ++i)
#define pc __builtin_popcount // counts number of 1's in bin(num)

const double pi = 2*acos(0.0);
//__gcd(n1, n2);
//cout << fixed;
//cout << setprecision(6); //fixes # of dp

const int mxN=2e5, M=998244353;
int n;
ar<int, 2> a[mxN];
ll dp[mxN+1];

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

	cin >> n;
	for(i, 0, n){
		cin >> a[i][0] >> a[i][1];
    }
	sort(a, a+n);
	dp[n]=1;
	vector<ar<int, 2>> st{{n, (int)2e9}};
	for(int i=n-1; ~i; --i) {
		while(st.back()[1]<a[i][0]+a[i][1])
			st.pop_back();
		int p=st.back()[0];
		dp[i]=dp[p];
		st.push_back({i, a[i][0]});
		dp[i]=(dp[i]+dp[i+1])%M;
	}
	cout << dp[0];
}

// not my code but nice ans







Compiler output:
a.cc: In function 'int main()':
a.cc:27:13: error: 'i' was not declared in this scope; did you mean 'pi'?
   27 |         for(i, 0, n){
      |             ^
      |             pi
a.cc:30:13: error: could not convert 'std::sort<array<int, 2>*>(((std::array<int, 2>*)(& a)), (((std::array<int, 2>*)(& a)) + ((sizetype)(((long unsigned int)n) * 8))))' from 'void' to 'bool'
   30 |         sort(a, a+n);
      |         ~~~~^~~~~~~~
      |             |
      |             void
a.cc:31:16: error: expected ')' before ';' token
   31 |         dp[n]=1;
      |                ^
      |                )
a.cc:27:12: note: to match this '('
   27 |         for(i, 0, n){
      |            ^
Language: C++

#define _GLIBCXX_DEBUG
#include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define dunk(n) cout << n << endl
#define all(a) (a).begin(),(a).end()
int main() {
    string s;
    cin >> s;
    if(s == "AAA" || s == "BBB"){
        dunk(Yes);
    }
    else dunk(No);
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:14: error: 'Yes' was not declared in this scope
   11 |         dunk(Yes);
      |              ^~~
a.cc:5:25: note: in definition of macro 'dunk'
    5 | #define dunk(n) cout << n << endl
      |                         ^
a.cc:13:15: error: 'No' was not declared in this scope
   13 |     else dunk(No);
      |               ^~
a.cc:5:25: note: in definition of macro 'dunk'
    5 | #define dunk(n) cout << n << endl
      |                         ^
Language: C++

#include<string>
#include<iostream>
#include <algorithm>
#include<vector>
#include<functional>
#include <cstdlib>
#define ll long long
using namespace std;



int main(){
   
  string S;

  cin>>S;

  if((S[0]=='A'S[1]=='A'S[2]=='A')||(S[0]=='B'S[1]=='B'S[2]=='B')){
     cout<<"No"<<endl;
  }
  else cout<<"Yes"<<endl;
  
    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:18:13: error: unable to find character literal operator 'operator""S' with 'char' argument
   18 |   if((S[0]=='A'S[1]=='A'S[2]=='A')||(S[0]=='B'S[1]=='B'S[2]=='B')){
      |             ^~~~
a.cc:18:22: error: unable to find character literal operator 'operator""S' with 'char' argument
   18 |   if((S[0]=='A'S[1]=='A'S[2]=='A')||(S[0]=='B'S[1]=='B'S[2]=='B')){
      |                      ^~~~
a.cc:18:44: error: unable to find character literal operator 'operator""S' with 'char' argument
   18 |   if((S[0]=='A'S[1]=='A'S[2]=='A')||(S[0]=='B'S[1]=='B'S[2]=='B')){
      |                                            ^~~~
a.cc:18:53: error: unable to find character literal operator 'operator""S' with 'char' argument
   18 |   if((S[0]=='A'S[1]=='A'S[2]=='A')||(S[0]=='B'S[1]=='B'S[2]=='B')){
      |                                                     ^~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main(){
  vector<char> a(3);
  for(int i=0; i<3; i++){
    cin>>a[i];
  }
  if(a[0]==a[1] && a[1]== a[2]){
    cout<<"No"<<endl;
  else{
    cout<<"Yes"<<endl;
  }
  return 0;
  }
                          

Compiler output:
a.cc: In function 'int main()':
a.cc:10:3: error: expected '}' before 'else'
   10 |   else{
      |   ^~~~
a.cc:8:32: note: to match this '{'
    8 |   if(a[0]==a[1] && a[1]== a[2]){
      |                                ^
Language: C++

mt19937 rng(chrono::steady_clock::now().time_since_epoch().count());
 
const int MOD = 1000000007;
const ll INF = 1e18;
const int MX = 100001; //check the limits, dummy
 
int main() {
	ios_base::sync_with_stdio(0); cin.tie(0);    
	
    string S; cin >> S;
    if (S[0] == S[1] && S[1] == S[2]) {
        cout << "No" << endl;
    } else {
        cout << "Yes" << endl;
    }
	
	return 0;
}
 

Compiler output:
a.cc:1:1: error: 'mt19937' does not name a type
    1 | mt19937 rng(chrono::steady_clock::now().time_since_epoch().count());
      | ^~~~~~~
a.cc:4:7: error: 'll' does not name a type
    4 | const ll INF = 1e18;
      |       ^~
a.cc: In function 'int main()':
a.cc:8:9: error: 'ios_base' has not been declared
    8 |         ios_base::sync_with_stdio(0); cin.tie(0);
      |         ^~~~~~~~
a.cc:8:39: error: 'cin' was not declared in this scope
    8 |         ios_base::sync_with_stdio(0); cin.tie(0);
      |                                       ^~~
a.cc:10:5: error: 'string' was not declared in this scope
   10 |     string S; cin >> S;
      |     ^~~~~~
a.cc:10:22: error: 'S' was not declared in this scope
   10 |     string S; cin >> S;
      |                      ^
a.cc:12:9: error: 'cout' was not declared in this scope
   12 |         cout << "No" << endl;
      |         ^~~~
a.cc:12:25: error: 'endl' was not declared in this scope
   12 |         cout << "No" << endl;
      |                         ^~~~
a.cc:14:9: error: 'cout' was not declared in this scope
   14 |         cout << "Yes" << endl;
      |         ^~~~
a.cc:14:26: error: 'endl' was not declared in this scope
   14 |         cout << "Yes" << endl;
      |                          ^~~~
Language: C++

#agma GCC optimize ("O3")
#pragma GCC target ("sse4")
 
#include <bits/stdc++.h>
#include <ext/pb_ds/tree_policy.hpp>
#include <ext/pb_ds/assoc_container.hpp>
 
using namespace std;
using namespace __gnu_pbds;
 
typedef long long ll;
typedef long double ld;
typedef complex<ld> cd;
 
typedef pair<int, int> pi;
typedef pair<ll,ll> pl;
typedef pair<ld,ld> pd;
 
typedef vector<int> vi;
typedef vector<ld> vd;
typedef vector<ll> vl;
typedef vector<pi> vpi;
typedef vector<pl> vpl;
typedef vector<cd> vcd;
 
template <class T> using Tree = tree<T, null_type, less<T>, rb_tree_tag,tree_order_statistics_node_update>;
 
#define FOR(i, a, b) for (int i=a; i<(b); i++)
#define F0R(i, a) for (int i=0; i<(a); i++)
#define FORd(i,a,b) for (int i = (b)-1; i >= a; i--)
#define F0Rd(i,a) for (int i = (a)-1; i >= 0; i--)
 
#define sz(x) (int)(x).size()
#define mp make_pair
#define pb push_back
#define f first
#define s second
#define lb lower_bound
#define ub upper_bound
#define all(x) x.begin(), x.end()
 
mt19937 rng(chrono::steady_clock::now().time_since_epoch().count());
 
const int MOD = 1000000007;
const ll INF = 1e18;
const int MX = 100001; //check the limits, dummy
 
int main() {
	ios_base::sync_with_stdio(0); cin.tie(0);    
	
    string S; cin >> S;
    if (S[0] == S[1] && S[1] == S[2]) {
        cout << "No" << endl;
    } else {
        cout << "Yes" << endl;
    }
	
	return 0;
}
 
// read the question correctly (ll vs int)
// template by bqi343
 

Compiler output:
a.cc:1:2: error: invalid preprocessing directive #agma; did you mean #pragma?
    1 | #agma GCC optimize ("O3")
      |  ^~~~
      |  pragma
Language: C++

#pragma GCC optimize ("O3")
#pragma GCC target ("sse4")
 
#include <bits/stdc++.h>
#include <ext/pb_ds/tree_policy.hpp>
#include <ext/pb_ds/assoc_container.hpp>
 
using namespace std;
using namespace __gnu_pbds;
 
typedef long long ll;
typedef long double ld;
typedef complex<ld> cd;
 
typedef pair<int, int> pi;
typedef pair<ll,ll> pl;
typedef pair<ld,ld> pd;
 
typedef vector<int> vi;
typedef vector<ld> vd;
typedef vector<ll> vl;
typedef vector<pi> vpi;
typedef vector<pl> vpl;
typedef vector<cd> vcd;
 
template <class T> using Tree = tree<T, null_type, less<T>, rb_tree_tag,tree_order_statistics_node_update>;
 
#define FOR(i, a, b) for (int i=a; i<(b); i++)
#define F0R(i, a) for (int i=0; i<(a); i++)
#define FORd(i,a,b) for (int i = (b)-1; i >= a; i--)
#define F0Rd(i,a) for (int i = (a)-1; i >= 0; i--)
 
#define sz(x) (int)(x).size()
#define mp make_pair
#define pb push_back
#define f first
#define s second
#define lb lower_bound
#define ub upper_bound
#define all(x) x.begin(), x.end()
 
mt19937 rng(chrono::steady_clock::now().time_since_epoch().count());
 
const int MOD = 1000000007;
const ll INF = 1e18;
const int MX = 100001; //check the limits, dummy
 
int main() {
	ios_base::sync_with_stdio(0); cin.tie(0);    
	
    string S; cin >> S;
    if (S[0] == S[1] && S[1] == S[2]) {
        cout << "No" << endl;
    } else {
        cout << "Yes" << endl;
    }
	
	return 0;
}
 
// read the question correctly (ll vs int)
// template by bqi343
 

Compiler output:
In file included from /usr/include/c++/14/string:43,
                 from /usr/include/c++/14/bitset:52,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:52,
                 from a.cc:4:
/usr/include/c++/14/bits/allocator.h: In destructor 'std::__cxx11::basic_string<char>::_Alloc_hider::~_Alloc_hider()':
/usr/include/c++/14/bits/allocator.h:182:7: error: inlining failed in call to 'always_inline' 'std::allocator< <template-parameter-1-1> >::~allocator() noexcept [with _Tp = char]': target specific option mismatch
  182 |       ~allocator() _GLIBCXX_NOTHROW { }
      |       ^
In file included from /usr/include/c++/14/string:54:
/usr/include/c++/14/bits/basic_string.h:186:14: note: called from here
  186 |       struct _Alloc_hider : allocator_type // TODO check __is_final
      |              ^~~~~~~~~~~~
Language: Java

import java.util.Scanner;

class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    String s = sc.nextLine();
    Boolean f = (s[0] != s[1] || s[0] != s[2] || s[1] != s[2]);
    if(f) {
      System.out.println("Yes");
    } else {
	  System.out.println("No");
    }
  }
}

Compiler output:
Main.java:7: error: array required, but String found
    Boolean f = (s[0] != s[1] || s[0] != s[2] || s[1] != s[2]);
                  ^
Main.java:7: error: array required, but String found
    Boolean f = (s[0] != s[1] || s[0] != s[2] || s[1] != s[2]);
                          ^
Main.java:7: error: array required, but String found
    Boolean f = (s[0] != s[1] || s[0] != s[2] || s[1] != s[2]);
                                  ^
Main.java:7: error: array required, but String found
    Boolean f = (s[0] != s[1] || s[0] != s[2] || s[1] != s[2]);
                                          ^
Main.java:7: error: array required, but String found
    Boolean f = (s[0] != s[1] || s[0] != s[2] || s[1] != s[2]);
                                                  ^
Main.java:7: error: array required, but String found
    Boolean f = (s[0] != s[1] || s[0] != s[2] || s[1] != s[2]);
                                                          ^
6 errors
Language: Java

import java.util.Scanner;

class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    String s = sc.nextLine();
    Boolean f = (s[0] != s[1] || s[0] != [2] || s[1] != s[2]);
    if(f) {
      System.out.println("Yes");
    } else {
	  System.out.println("No");
    }
  }
}

Compiler output:
Main.java:7: error: illegal start of expression
    Boolean f = (s[0] != s[1] || s[0] != [2] || s[1] != s[2]);
                                         ^
Main.java:7: error: ';' expected
    Boolean f = (s[0] != s[1] || s[0] != [2] || s[1] != s[2]);
                                                            ^
2 errors
Language: Java

import java.util.Scanner;

class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    String s = sc.nextLine();
    if(s[0] != s[1] || s[0] != [2] || s[1] != s[2]) {
      System.out.println("Yes");
    } else {
	  System.out.println("No");
    }
  }
}

Compiler output:
Main.java:7: error: illegal start of expression
    if(s[0] != s[1] || s[0] != [2] || s[1] != s[2]) {
                               ^
Main.java:7: error: not a statement
    if(s[0] != s[1] || s[0] != [2] || s[1] != s[2]) {
                                           ^
Main.java:7: error: ';' expected
    if(s[0] != s[1] || s[0] != [2] || s[1] != s[2]) {
                                                  ^
Main.java:9: error: 'else' without 'if'
    } else {
      ^
4 errors
Language: Java

import java.util.Scanner;

class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    String s = sc.nextLine();
    if(a[0] != s[1] || s[0] != [2] || s[1] != s[2]) {
      System.out.println("Yes");
    } else {
	  System.out.println("No");
    }
  }
}

Compiler output:
Main.java:7: error: illegal start of expression
    if(a[0] != s[1] || s[0] != [2] || s[1] != s[2]) {
                               ^
Main.java:7: error: not a statement
    if(a[0] != s[1] || s[0] != [2] || s[1] != s[2]) {
                                           ^
Main.java:7: error: ';' expected
    if(a[0] != s[1] || s[0] != [2] || s[1] != s[2]) {
                                                  ^
Main.java:9: error: 'else' without 'if'
    } else {
      ^
4 errors
Language: Java

import java.util.Scanner;
 
public class Main {
  public static void main(String[] args) 
  {
    String[] lines = getStdin();
    char[] buses = lines[0].toCharArray();
     
    if (buses[0] == buses[1] && buses[1] == buses[2])
    {
        System.out.print("No");
    }
    else
    {
    	System.out.print("Yes");
  	}
  }
  
  private static String[] getStdin() {
    Scanner scanner = new Scanner(System.in);
    ArrayList<String> lines = new ArrayList<>();
    while (scanner.hasNext()) {
      lines.add(scanner.nextLine());
    }
    return lines.toArray(new String[lines.size()]);
  }


Compiler output:
Main.java:26: error: reached end of file while parsing
  }
   ^
1 error
Language: Java

import java.util.Scanner;

public class Main {
  public static void main(String[] args) 
  {
    String[] lines = getStdin();
    char[] buses = lines[0].toCharArray();
     
    if (buses[0] == buses[1] && buses[1] == buses[2])
    {
        System.out.print("No");
    }
    else
    {
    	System.out.print("Yes");}
  	}
  
  private static String[] getStdin() {
    Scanner scanner = new Scanner(System.in);
    ArrayList<String> lines = new ArrayList<>();
    while (scanner.hasNext()) {
      lines.add(scanner.nextLine());
    }
    return lines.toArray(new String[lines.size()]);
  }

Compiler output:
Main.java:25: error: reached end of file while parsing
  }
   ^
1 error
Language: C++

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

int main() {
	long long a, b, n, ans;
	cin >> n;
	cin >> a >> b;

	if (a + b == 0) {
		cout << 0 << endl;
		return 0;
	}

	long long sur = n % (a + b);
	long long quo = n / (a + b);

	if (quo == 0) {
		ans = min(a, sur);
	}
	else {
		ans = a * quo + min(a, sur);
	}

	cout << ans << endl;

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

#include <bits/stdc++.h>
using namespace std;
int main(){
	// freopen("input.txt", "r", stdin);
	// freopen("output.txt", "w", stdout);
	ios::sync_with_stdio(0), cin.tie(0), cout.tie(0);
	string s;
	cin>>s;
	bool a = false, b = false;
	for (int i=1; i<=n; i++){
		if (s[i] == 'A'){
			a = true;
		}
		else if (s[i] == 'B'){
			b = true;
		}
	}
	if (a == true && b == true){
		cout<<"Yes";
	}
	esle{
		cout<<"No";
	}
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:26: error: 'n' was not declared in this scope
   10 |         for (int i=1; i<=n; i++){
      |                          ^
a.cc:21:9: error: 'esle' was not declared in this scope
   21 |         esle{
      |         ^~~~
Language: C++

#include<iostream>
using namespace std;
int main()
{
  string s;
  int a=0;
  int b=0;
  cin>>s;
  for(int i=0;i<3;i++)
  {
    if(s[i]=='A')
    {
      a++;
    }
    else if(s[i]='B')
    {
      b++;
    }
    if(a>0&&b>0)
    {
      cout<<"Yes"<<endl;
    }
    else 
    {
      cout<<"No"<<endl;
    }
  }

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

char temp;
char str[4];
scanf("%s", str);
int i;
int j;
for(i=0;i<4;i++){
	temp=str[i];
  	for(j=i+1;j<4;j++){
      		if(temp==str[j]){
      		printf("Yes");
        	}
    }
}



Compiler output:
a.cc:3:6: error: expected constructor, destructor, or type conversion before '(' token
    3 | scanf("%s", str);
      |      ^
a.cc:6:1: error: expected unqualified-id before 'for'
    6 | for(i=0;i<4;i++){
      | ^~~
a.cc:6:9: error: 'i' does not name a type
    6 | for(i=0;i<4;i++){
      |         ^
a.cc:6:13: error: 'i' does not name a type
    6 | for(i=0;i<4;i++){
      |             ^
Language: C++

int main()
{
char temp;
char str[4];
scanf("%s", str);
int i;
int j;
for(i=0;i<4;i++){
	temp=str[i];
  	for(j=i+1;j<4;j++){
      		if(temp==str[j]){
      		printf("Yes");
        	}
    }
}
return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:5:1: error: 'scanf' was not declared in this scope
    5 | scanf("%s", str);
      | ^~~~~
a.cc:12:17: error: 'printf' was not declared in this scope
   12 |                 printf("Yes");
      |                 ^~~~~~
a.cc:1:1: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
  +++ |+#include <cstdio>
    1 | int main()
Language: C++

int main()
{
char temp;
char str[4];
scanf("%s", str);
int i;
for(i=0;i<4;i++){
	temp=str[i];
  	for(j=i+1;j<4;j++){
      		if(temp==str[j]){
      		printf("Yes");
        	}
    }
}
return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:5:1: error: 'scanf' was not declared in this scope
    5 | scanf("%s", str);
      | ^~~~~
a.cc:9:13: error: 'j' was not declared in this scope
    9 |         for(j=i+1;j<4;j++){
      |             ^
a.cc:11:17: error: 'printf' was not declared in this scope
   11 |                 printf("Yes");
      |                 ^~~~~~
a.cc:1:1: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
  +++ |+#include <cstdio>
    1 | int main()
Language: C++

char temp;
char str[4];
scanf("%s", str);
int i;
for(i=0;i<4;i++){
	temp=str[i];
  	for(j=i+1;j<4;j++){
      	if(temp==str[j]){
      	printf("Yes");
        }
    }
}


Compiler output:
a.cc:3:6: error: expected constructor, destructor, or type conversion before '(' token
    3 | scanf("%s", str);
      |      ^
a.cc:5:1: error: expected unqualified-id before 'for'
    5 | for(i=0;i<4;i++){
      | ^~~
a.cc:5:9: error: 'i' does not name a type
    5 | for(i=0;i<4;i++){
      |         ^
a.cc:5:13: error: 'i' does not name a type
    5 | for(i=0;i<4;i++){
      |             ^
Language: C++

char temp='A';
char str[4];
scanf("%s", str);
for(i=0;i<4;i++){
	temp=str[i];
  	if(temp=str[i+1]){
      printf("Yes");
    }
}

Compiler output:
a.cc:3:6: error: expected constructor, destructor, or type conversion before '(' token
    3 | scanf("%s", str);
      |      ^
a.cc:4:1: error: expected unqualified-id before 'for'
    4 | for(i=0;i<4;i++){
      | ^~~
a.cc:4:9: error: 'i' does not name a type
    4 | for(i=0;i<4;i++){
      |         ^
a.cc:4:13: error: 'i' does not name a type
    4 | for(i=0;i<4;i++){
      |             ^
Language: C

#include <stdio.h>
int main(){
  char c[3];
  gets(c)
  if(c[1] == c[2] && c[1] == c[3]){
    printf("Yes");
  }
  
  else{
    printf("No");
  }
  
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:4:3: error: implicit declaration of function 'gets'; did you mean 'fgets'? [-Wimplicit-function-declaration]
    4 |   gets(c)
      |   ^~~~
      |   fgets
main.c:4:10: error: expected ';' before 'if'
    4 |   gets(c)
      |          ^
      |          ;
    5 |   if(c[1] == c[2] && c[1] == c[3]){
      |   ~~
Language: C

#include <stdio.h>
int main(){
  char c[3];
  scanf("%s",c)
  if(c[1] == c[2] && c[1] == c[3]){
    printf("Yes");
  }
  
  else{
    printf("No");
  }
  
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:4:16: error: expected ';' before 'if'
    4 |   scanf("%s",c)
      |                ^
      |                ;
    5 |   if(c[1] == c[2] && c[1] == c[3]){
      |   ~~
Language: C

#include <stdio.h>
int main(){
  char c[3],c);
  scanf("%s"
  if(c[1] == c[2] && c[1] == c[3]){
    printf("Yes");
  }
  
  else{
    printf("No");
  }
  
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:3:14: error: expected '=', ',', ';', 'asm' or '__attribute__' before ')' token
    3 |   char c[3],c);
      |              ^
main.c:4:13: error: expected ')' before 'if'
    4 |   scanf("%s"
      |        ~    ^
      |             )
    5 |   if(c[1] == c[2] && c[1] == c[3]){
      |   ~~         
main.c:13:12: error: expected ';' before '}' token
   13 |   return 0;
      |            ^
      |            ;
   14 | }
      | ~
Language: C++

#include <iostream>
#include <string>

int main(void){
  string line;

  cin >> line;

  if ( line == "AAA" || line == "BBB" ){
    cout << "No\n";
  }else{
    cout << "Yes\n";
  }
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:5:3: error: 'string' was not declared in this scope
    5 |   string line;
      |   ^~~~~~
a.cc:5:3: note: suggested alternatives:
In file included from /usr/include/c++/14/iosfwd:41,
                 from /usr/include/c++/14/ios:40,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/bits/stringfwd.h:77:33: note:   'std::string'
   77 |   typedef basic_string<char>    string;
      |                                 ^~~~~~
In file included from /usr/include/c++/14/bits/locale_classes.h:40,
                 from /usr/include/c++/14/bits/ios_base.h:41,
                 from /usr/include/c++/14/ios:44:
/usr/include/c++/14/string:76:11: note:   'std::pmr::string'
   76 |     using string    = basic_string<char>;
      |           ^~~~~~
a.cc:7:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    7 |   cin >> line;
      |   ^~~
      |   std::cin
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:7:10: error: 'line' was not declared in this scope
    7 |   cin >> line;
      |          ^~~~
a.cc:10:5: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   10 |     cout << "No\n";
      |     ^~~~
      |     std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:12:5: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   12 |     cout << "Yes\n";
      |     ^~~~
      |     std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
Language: C++

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

int main(){
    string S;
    cin >> S;
    if(S[0] =! S[1] || S[0] =! S[2] || S[1] =! S[2]){
        cout << "Yes" << endl;
        return 0;
    }
    cout << "No" << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:37: error: lvalue required as left operand of assignment
    7 |     if(S[0] =! S[1] || S[0] =! S[2] || S[1] =! S[2]){