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

#include <iostream>
#include <bitset>
#include <vector>
#include <string>
#include <algorithm>
#include <set>
#include <map>
#include <cmath>
#include <regex>
using namespace std;
using ll = long long int;
using dd = long double;
const ll MOD = 1e9 + 7;

vector<string> dfs(string s, ll depth, vector<char> symbol)
{
    vector<string> ret;
    if (depth == 0)
    {
        ret.push_back(s);
        return ret;
    }

    for (ll i = 0; i < symbol.size(); i++)
    {
        auto vec = dfs(s + symbol[i], depth - 1, symbol);
        for (auto &&e : vec)
        {
            ret.push_back(e);
        }
    }
    return ret;
}

ll gcd(ll a, ll b)
{
    if (a % b == 0)
    {
        return b;
    }
    return gcd(b, a % b);
}

int main()
{
    ll A, B;
    cin >> A >> B;

    if (A + B >= 10)
    {
        cout << "error" << endl;
        return;
    }
    cout << A + B << endl;
}

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

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

int main() {
  int x, y;
  cin >> x >> y;
  if (a + b < 10) cout << a + b << endl;
  else cout << "error" << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:7: error: 'a' was not declared in this scope
    8 |   if (a + b < 10) cout << a + b << endl;
      |       ^
a.cc:8:11: error: 'b' was not declared in this scope
    8 |   if (a + b < 10) cout << a + b << endl;
      |           ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define PI 3.14159265358979323846
constexpr int INF = numeric_limits<int>::max() / 2;
constexpr long long INFL = numeric_limits<long long>::max() / 2;
constexpr int MOD = 1000000007;
using Graph = vector<vector<int>>;



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

    int A,B;
    cin >>A>>B;
    if(A+B>=10) cout <<"error" <<endl;
    elsecout <<A+B  << endl;



}


Compiler output:
a.cc: In function 'int main()':
a.cc:19:5: error: 'elsecout' was not declared in this scope
   19 |     elsecout <<A+B  << endl;
      |     ^~~~~~~~
Language: C++

#include <bits/stdc++.h>

using namespace std;

int main() {

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

	cout << ((a + b > 9)? "error" : ltoa(a + b)) << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:41: error: 'ltoa' was not declared in this scope
   10 |         cout << ((a + b > 9)? "error" : ltoa(a + b)) << endl;
      |                                         ^~~~
Language: C++

#include <bits/stdc++.h>
#define rep(i, z, n) for(int i = z; i < n; i++)
#define all(v) v.begin(), v.end()
typedef long long ll;
//const int INF = 1<<29;
//const int MODINF = 1000000007;
using namespace std;

int main(){
    int A, B;
    cin >> A >> B;
    if (A + B >= 10) cout << "error" << endl;
    else cout << A + B << endl;
}#include <bits/stdc++.h>
#define rep(i, z, n) for(int i = z; i < n; i++)
#define all(v) v.begin(), v.end()
typedef long long ll;
//const int INF = 1<<29;
//const int MODINF = 1000000007;
using namespace std;

int main(){
    int A, B;
    cin >> A >> B;
    if (A + B >= 10) cout << "error" << endl;
    else cout << A + B << endl;
}

Compiler output:
a.cc:14:2: error: stray '#' in program
   14 | }#include <bits/stdc++.h>
      |  ^
a.cc:14:3: error: 'include' does not name a type
   14 | }#include <bits/stdc++.h>
      |   ^~~~~~~
a.cc:22:5: error: redefinition of 'int main()'
   22 | int main(){
      |     ^~~~
a.cc:9:5: note: 'int main()' previously defined here
    9 | int main(){
      |     ^~~~
Language: Java

import java.util.*;

public class Main {
  public static void main(String[] args) {
    	Scanner sc = new Scanner(System.in);
    	int a = sc.nextInt();
    	int b = sc.nextInt();
    	if(a + b >= 10){
          System.out.println("error");
        } else {
          System.out.println(a + b);
  }
}

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

#include <iostream>
#include <numeric>
#include <iomanip>
#include <string> // string, to_string, stoi
#include <vector> // vector
#include <algorithm> // min, max, swap, sort, reverse, lower_bound, upper_bound
#include <utility> // pair, make_pair
#include <tuple> // tuple, make_tuple
#include <cstdint> // int64_t, int*_t
#include <cstdio> // printf
#include <map> // map
#include <queue> // queue, priority_queue
#include <set> // set
#include <stack> // stack
#include <deque> // deque
#include <unordered_map> // unordered_map
#include <unordered_set> // unordered_set
#include <bitset> // bitset
#include <cctype> // isupper, islower, isdigit, toupper, tolower
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)




int main() {

	int A, B;
	cin >> A >> B;

	if (A + B > 9) {
		cout << "error" << endl;
	}
	else
		cout << A + B << endl;
}
}

Compiler output:
a.cc:37:1: error: expected declaration before '}' token
   37 | }
      | ^
Language: C++

#include <iostream>
#include <algorithm>
#include <iomanip>
using namespace std;
string alphabet = "abcdefghijklmnopqrstuvwxyz";
string ALPHABET = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";

int main(){
  int a , b;
  cin >> a >> b;
  int k = a + b;
  if(k < 10)cout << k << endl;
  else << "error" << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:13:8: error: expected primary-expression before '<<' token
   13 |   else << "error" << endl;
      |        ^~
Language: C++

#include <bits/stdc++.h>
#define rep(i,n) for (ll i=0; i<(n); i++)
using namespace std;
typedef long long ll;
typedef pair<int,int> P;
int dx[4]={1,0,-1,0};
int dy[4]={0,1,0,-1};
template<class T> inline bool chmax(T& a, T b) { if (a < b) { a = b; return 1; } return 0; }
template<class T> inline bool chmin(T& a, T b) { if (a > b) { a = b; return 1; } return 0; }

int main(){
    int A,B; cin >> A >> B;
    if (A+B>=10) cout << "error" << endl;
    else cout << A+B << endl;
    retrun 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:15:5: error: 'retrun' was not declared in this scope
   15 |     retrun 0;
      |     ^~~~~~
Language: C++

#include <cstdio>

int a,b;

scanf("%d %d",&a,&b);

if(a+b >= 10)
{
  printf("error");
}
else
{
  printf("%d",a+b);
}

Compiler output:
a.cc:5:6: error: expected constructor, destructor, or type conversion before '(' token
    5 | scanf("%d %d",&a,&b);
      |      ^
a.cc:7:1: error: expected unqualified-id before 'if'
    7 | if(a+b >= 10)
      | ^~
a.cc:11:1: error: expected unqualified-id before 'else'
   11 | else
      | ^~~~
Language: C++

#include <cstdio>

int a,b;

scanf("%d %d",&a,&b);

if(a+b == 10)
{
  printf("error");
}
else
{
  printf("%d+%d",a,b);
}

Compiler output:
a.cc:5:6: error: expected constructor, destructor, or type conversion before '(' token
    5 | scanf("%d %d",&a,&b);
      |      ^
a.cc:7:1: error: expected unqualified-id before 'if'
    7 | if(a+b == 10)
      | ^~
a.cc:11:1: error: expected unqualified-id before 'else'
   11 | else
      | ^~~~
Language: C++

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

int main(){
  int A,B;
  cin >> A >> B;
  cout << (A + B >= 10 ? "error" : A + B) << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:24: error: operands to '?:' have different types 'const char*' and 'int'
    7 |   cout << (A + B >= 10 ? "error" : A + B) << endl;
      |            ~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
Language: C++

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

int main() {

  int a,b;
  cin  >> a >> b;
  
  if ( a + b < 10 ){
    cout << a + b << endl:
  }else{
    cout << "error" << endl;
  }
  
}



Compiler output:
a.cc: In function 'int main()':
a.cc:10:26: error: expected ';' before ':' token
   10 |     cout << a + b << endl:
      |                          ^
      |                          ;
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){
int A,B;
  cin>>A>>B;
  if(A+B>=10)
  {
  cout<<"error"<<endl:
  }
  else{
  cout<<A+B<<endl;
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:22: error: expected ';' before ':' token
    8 |   cout<<"error"<<endl:
      |                      ^
      |                      ;
Language: C++

#include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (n); ++i)
#define zero_pad(num) setfill('0') << std::right << setw(num)
using namespace std;
using ll = long long;
using ld = long double;
using P = pair<int, int>;

int main() {
    int a, b;
    cin >> a >> b;
    cout << ((a + b < 10) ? a + b : "error") << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:27: error: operands to '?:' have different types 'int' and 'const char*'
   12 |     cout << ((a + b < 10) ? a + b : "error") << endl;
      |              ~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
Language: C++

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

int main(){
    int a,b;
    cin >> a >> b;
    cout << (a+b >= 10 ? "error" : a+b) << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:24: error: operands to '?:' have different types 'const char*' and 'int'
    7 |     cout << (a+b >= 10 ? "error" : a+b) << endl;
      |              ~~~~~~~~~~^~~~~~~~~~~~~~~
Language: C++

#include <bits/stdc++.h>
#include <ext/pb_ds/tree_policy.hpp>
#include <ext/pb_ds/assoc_container.hpp>
#define IO(i, o) freopen(i, "r", stdin), freopen(o, "w", stdout)

using namespace std;
using namespace __gnu_pbds;
typedef tree<int, null_type, less<int>, rb_tree_tag, tree_order_statistics_node_update> indexed_set;
mt19937 rng((uint32_t)chrono::steady_clock::now().time_since_epoch().count());

int a, b;

int main(){
	//IO("input.txt", "output.txt");
	ios_base::sync_with_stdio(false);
	cin.tie(NULL);
	cin >> a >> b;
	cout << ((a + b >= 10) ? "error\n" : a + b);
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:18:32: error: operands to '?:' have different types 'const char*' and 'int'
   18 |         cout << ((a + b >= 10) ? "error\n" : a + b);
      |                  ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main(){
  int a,b;
  cin >> a >> b;
  if(a+b>=10){
    cout << "error" << endl;
  }else{
    cout << a+b << endl;
  return 0;
}

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

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

int main() {
  cin.tie(nullptr); ios::sync_with_stdio(false);
  int A, B;
  cin >> A >> B;
  cout << (A + B >= 10 ? "error" : A + B) << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:9:24: error: operands to '?:' have different types 'const char*' and 'int'
    9 |   cout << (A + B >= 10 ? "error" : A + B) << endl;
      |            ~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
#define rep(i,n) for(int i=0;i<(int)(n);i++)
int main(){
    string s; cin >> s;
    int n = s.size();
    bool flag = false
    for(int i = 0; i < n; i++){
        for(int j = i+1; j < n; j++){
            if(s[i]==s[j]){
                flag = true;
                break;
            }
        }
        if(flag){
            break;
        }
    }

    if(flag){
        cout << "no" << endl;
    }else{
        cout << "yes" << endl;
    }
}




Compiler output:
a.cc: In function 'int main()':
a.cc:8:5: error: expected ',' or ';' before 'for'
    8 |     for(int i = 0; i < n; i++){
      |     ^~~
a.cc:8:20: error: 'i' was not declared in this scope
    8 |     for(int i = 0; i < n; i++){
      |                    ^
Language: C++

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

int main() {
  int A, B;
  cin >> A >> B;
  sum = A + B;
  if (sum >= 10) {
    cout << "error" << endl;
  } else {
    cout << sum << endl;
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:3: error: 'sum' was not declared in this scope
    7 |   sum = A + B;
      |   ^~~
Language: C++

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

int grouping(int n) {
  int A, B;
  cin >> A >> B;
  sum = A + B;
  if (sum >= 10) {
    cout << "error" << endl;
  } else {
    cout << sum << endl;
  }
}

Compiler output:
a.cc: In function 'int grouping(int)':
a.cc:7:3: error: 'sum' was not declared in this scope
    7 |   sum = A + B;
      |   ^~~
a.cc:13:1: warning: no return statement in function returning non-void [-Wreturn-type]
   13 | }
      | ^
Language: C++

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

int main() {
  int a,b;cin>>a>>b;
  cout << (a+b>9) ? "error" : a+b;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:19: error: operands to '?:' have different types 'const char*' and 'int'
    7 |   cout << (a+b>9) ? "error" : a+b;
      |   ~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~
Language: C++

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

// #define int long long
#define endl '\n'
#define ll long long
#define ld long double
#define fi first
#define se second
#define pii pair<int, int>
#define pll pair<long long, long long>
#define mod (ll) (1e9 + 7)
#define fast ios_base::sync_with_stdio(false);cin.tie(NULL);
#define all(v) v.begin(), v.end()
#define dvec(v) for(auto i: v) cout<< i<< " "; cout<< '\n';
#define gcd(a,b) __gcd(a, b)
#define lcm(a,b) ((a)*((b)/gcd(a,b)))
#define darr(a,n) for(int i=0; i<n;i++) cout<< a[i]<< " "; cout<< '\n';
#define what_is(x) cerr<< #x<< " : "<< x<< '\n';


int32_t main() {
	fast;
	int a, b;
	cin >> a >> b;
	cout << (a + b > 9 ? "error" : a + b) << endl;

	return 0;
}


Compiler output:
a.cc: In function 'int32_t main()':
a.cc:26:28: error: operands to '?:' have different types 'const char*' and 'int'
   26 |         cout << (a + b > 9 ? "error" : a + b) << endl;
      |                  ~~~~~~~~~~^~~~~~~~~~~~~~~~~
Language: C++

using namespace std;
int main(){
  int a,b;
  cin>>a>>b;
  int c=a+b;
  if(c>=10){
    cout<<"error";
  }else{
    cout<<c;
  }
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:4:3: error: 'cin' was not declared in this scope
    4 |   cin>>a>>b;
      |   ^~~
a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
  +++ |+#include <iostream>
    1 | using namespace std;
a.cc:7:5: error: 'cout' was not declared in this scope
    7 |     cout<<"error";
      |     ^~~~
a.cc:7:5: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:9:5: error: 'cout' was not declared in this scope
    9 |     cout<<c;
      |     ^~~~
a.cc:9:5: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
Language: C++

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

int main(){
  int a,b,;
  cin>> a >> b;
  if(a+b<10) cout << a+b << endl;
  else cout << "error" << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:11: error: expected unqualified-id before ';' token
    5 |   int a,b,;
      |           ^
Language: C++

#include<iostream>
using namespace std;
int main(){
  int a,b;
  cin>>a>>b;
  cout<<((a+b<10)?a+b:"error")<<endl;}


Compiler output:
a.cc: In function 'int main()':
a.cc:6:18: error: operands to '?:' have different types 'int' and 'const char*'
    6 |   cout<<((a+b<10)?a+b:"error")<<endl;}
      |          ~~~~~~~~^~~~~~~~~~~~
Language: C++

#include<iostream>
using namespace std;
int main(){
  int a,b;
  cin>>a>>b;
  cout<<(a+b<10?a+b:"error")<<endl;}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:16: error: operands to '?:' have different types 'int' and 'const char*'
    6 |   cout<<(a+b<10?a+b:"error")<<endl;}
      |          ~~~~~~^~~~~~~~~~~~
Language: C++

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

int main() {
  int a,b; cin >> a >> b;
  int sum = a+b;
  cout << ((sum>=10) ? "error" : sum) << endl;
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:9:22: error: operands to '?:' have different types 'const char*' and 'int'
    9 |   cout << ((sum>=10) ? "error" : sum) << endl;
      |            ~~~~~~~~~~^~~~~~~~~~~~~~~
Language: C++

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

#ifdef LOCAL
#define debug(var) cerr << #var << " = " << var << endl;
#else
#define debug(var)
#endif

void init() {
	ios_base::sync_with_stdio(0);
	cin.tie(0); cout.tie(0);
}

void solve() {
	int a, b; cin >> a >> b;
	if (a+b >= 10) cout << "error"
	else cout << a+b;
}

int main() {
	init();
	int t = 1; //scanf("%d", &t);
	while (t--) {
		solve();
	}
	return 0;
}


Compiler output:
a.cc: In function 'void solve()':
a.cc:17:39: error: expected ';' before 'else'
   17 |         if (a+b >= 10) cout << "error"
      |                                       ^
      |                                       ;
   18 |         else cout << a+b;
      |         ~~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
#define REP(i,n) for(int i=0; i<(n); i++)
#define REP2(i,x,n) for(int i=x; i<(n); i++)
int main()
{
    int A,B;
    cin >> A>>B;

    cout << (A+B>=10?"error":A+B) << endl;

   return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:21: error: operands to '?:' have different types 'const char*' and 'int'
   10 |     cout << (A+B>=10?"error":A+B) << endl;
      |              ~~~~~~~^~~~~~~~~~~~
Language: C

#include <stdio.h>
int main(void){
	int x,y;
	scanf("%d%d",&x,&y);
	x+y<10 ? printf("%d",x+y); : printf("error");
	return 0;
}

Compiler output:
main.c: In function 'main':
main.c:5:34: error: expected ':' before ';' token
    5 |         x+y<10 ? printf("%d",x+y); : printf("error");
      |                                  ^
      |                                  :
main.c:5:36: error: expected expression before ':' token
    5 |         x+y<10 ? printf("%d",x+y); : printf("error");
      |                                    ^
Language: C++

#include<iostream>
using namespace std;
int main(){
  int a,b;
  cin >> a >> b;
  cout << ((a+b<10) ? a+b:"error") << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:21: error: operands to '?:' have different types 'int' and 'const char*'
    6 |   cout << ((a+b<10) ? a+b:"error") << endl;
      |            ~~~~~~~~~^~~~~~~~~~~~~
Language: C++

#include<cstdio>
using namespace std;
int pd(int a,int b)
{
    if(a+b>=10)
        return 0；
    return 1;
}
int main()
{
    int a,b;
    scanf("%d%d",&a,&b);
    if(pd(a,b))
        printf("%d%d,a+b);
    else
        printf("%d%d",0);
    return 0;  
}

Compiler output:
a.cc:14:16: warning: missing terminating " character
   14 |         printf("%d%d,a+b);
      |                ^
a.cc:14:16: error: missing terminating " character
   14 |         printf("%d%d,a+b);
      |                ^~~~~~~~~~~
a.cc: In function 'int pd(int, int)':
a.cc:6:16: error: unable to find numeric literal operator 'operator""\U0000ff1b'
    6 |         return 0；
      |                ^~~
a.cc:6:19: error: expected ';' before 'return'
    6 |         return 0；
      |                   ^
      |                   ;
    7 |     return 1;
      |     ~~~~~~         
a.cc: In function 'int main()':
a.cc:15:5: error: expected primary-expression before 'else'
   15 |     else
      |     ^~~~
Language: C++

    #include<iostream>
    #include<stdio.h>
    //#include <bits/stdc++.h>
    #include<vector>
    #include<float.h>
    #include<iomanip>
    #include<algorithm>
    #include<string>
    #include<cstring>
    #include<math.h>
    #include<cmath>
    #include<sstream>
    #include<set>
    #include<map>
    #include<queue>
    #include <cassert>
    #include <cmath>

    #define INF 1e9
    #define rep(i,n)for(int i=0;(i)<(int)(n);i++)
    #define REP(i,a,b)for(int i=(int)(a);(i)<=(int)(b);i++)
    #define VEC(type, c, n) std::vector<type> c(n);for(auto& i:c)std::cin>>i;
    #define vec(type,n) vector<type>(n)
    #define vvec(m,n) vector<vector<int>> (int(m),vector<int>(n))

    using namespace std;
    using ll = long long;
    using Graph = vector<vector<int>>;
    using P = pair<int,int>;


    int main(){
      int a,b;cin>>a>>b;
      cout<<(a+b<10 ? a+b : "error");
    }
    


Compiler output:
a.cc: In function 'int main()':
a.cc:34:21: error: operands to '?:' have different types 'int' and 'const char*'
   34 |       cout<<(a+b<10 ? a+b : "error");
      |              ~~~~~~~^~~~~~~~~~~~~~~
Language: C++

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

int main() {
  
  int A=0, B=0;
  
  cin >> A >> B;
  
  int sum = A+B;
  
  if(10<=sum) {
    
    cout << "error" << endl;
    
  } else {
    
    cout << sum << endl;
    
  } 
  
  return 0;
  
}

Compiler output:
a.cc:1:1: error: 'include' does not name a type
    1 | include <bits/stdc++.h>
      | ^~~~~~~
a.cc: In function 'int main()':
a.cc:8:3: error: 'cin' was not declared in this scope
    8 |   cin >> A >> B;
      |   ^~~
a.cc:14:5: error: 'cout' was not declared in this scope
   14 |     cout << "error" << endl;
      |     ^~~~
a.cc:14:24: error: 'endl' was not declared in this scope
   14 |     cout << "error" << endl;
      |                        ^~~~
a.cc:18:5: error: 'cout' was not declared in this scope
   18 |     cout << sum << endl;
      |     ^~~~
a.cc:18:20: error: 'endl' was not declared in this scope
   18 |     cout << sum << endl;
      |                    ^~~~
Language: C++

#include <iostream>
#include <cstdio>
#include <cstring>
#include <algorithm>
#include <cmath>
#include <queue>
#include <stack>
#include <map>
#include <set>
#include <vector>
#include <iomanip>
#define ALL(x) (x).begin(), (x).end()
#define sz(a) int(a.size())
#define rep(i,x,n) for(int i=x;i<n;i++)
#define repd(i,x,n) for(int i=x;i<=n;i++)
#define pii pair<int,int>
#define pll pair<long long ,long long>
#define gbtb ios::sync_with_stdio(false),cin.tie(0),cout.tie(0)
#define MS0(X) memset((X), 0, sizeof((X)))
#define MSC0(X) memset((X), '\0', sizeof((X)))
#define pb push_back
#define mp make_pair
#define fi first
#define se second
#define eps 1e-6
#define chu(x) cout<<"["<<#x<<" "<<(x)<<"]"<<endl
#define du3(a,b,c) scanf("%d %d %d",&(a),&(b),&(c))
#define du2(a,b) scanf("%d %d",&(a),&(b))
#define du1(a) scanf("%d",&(a));
using namespace std;
typedef long long ll;
ll gcd(ll a, ll b) {return b ? gcd(b, a % b) : a;}
ll lcm(ll a, ll b) {return a / gcd(a, b) * b;}
ll powmod(ll a, ll b, ll MOD) { if (a == 0ll) {return 0ll;} a %= MOD; ll ans = 1; while (b) {if (b & 1) {ans = ans * a % MOD;} a = a * a % MOD; b >>= 1;} return ans;}
void Pv(const vector<int> &V) {int Len = sz(V); for (int i = 0; i < Len; ++i) {printf("%d", V[i] ); if (i != Len - 1) {printf(" ");} else {printf("\n");}}}
void Pvl(const vector<ll> &V) {int Len = sz(V); for (int i = 0; i < Len; ++i) {printf("%lld", V[i] ); if (i != Len - 1) {printf(" ");} else {printf("\n");}}}
inline long long readll() {long long tmp = 0, fh = 1; char c = getchar(); while (c < '0' || c > '9') {if (c == '-') fh = -1; c = getchar();} while (c >= '0' && c <= '9') tmp = tmp * 10 + c - 48, c = getchar(); return tmp * fh;}
inline int readint() {int tmp = 0, fh = 1; char c = getchar(); while (c < '0' || c > '9') {if (c == '-') fh = -1; c = getchar();} while (c >= '0' && c <= '9') tmp = tmp * 10 + c - 48, c = getchar(); return tmp * fh;}
const int maxn = 1000010;
const int inf = 0x3f3f3f3f;
/*** TEMPLATE CODE * * STARTS HERE ***/

int main()
{
    //freopen("D:\\code\\text\\input.txt","r",stdin);
    //freopen("D:\\code\\text\\output.txt","w",stdout);
    int a, b;
    a = readint();
    b = readint();
    if (a + b + >= 10)
    {
        printf("error\n");
    } else
    {
        printf("%d\n", a + b );
    }
    return 0;
}




Compiler output:
a.cc: In function 'int main()':
a.cc:50:17: error: expected primary-expression before '>=' token
   50 |     if (a + b + >= 10)
      |                 ^~
Language: C++

#include<iostream>
using namespace std;
int main(){
    int a,b;
    cin>>a>>b;
    cout<<(a+b<=10?a+b:"error")<<endl;

}


Compiler output:
a.cc: In function 'int main()':
a.cc:6:19: error: operands to '?:' have different types 'int' and 'const char*'
    6 |     cout<<(a+b<=10?a+b:"error")<<endl;
      |            ~~~~~~~^~~~~~~~~~~~
Language: C++

#include<iostream>
#include<stdio.h>
#include<string>
#include<vector>
#include<map>
#include<tuple>
#include<algorithm>
#include<cmath>
#include<limits>
#include<set>
#include<queue>
using namespace std;
#define int long  long int
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
int gcd(int a, int b) { return b ? gcd(b, a % b) : a; }
int lcm(int a, int b) { return a / gcd(a, b) * b; }
typedef pair<int, int>P;
const int INF = 1e15;

signed main() {
	int A, B;
	cin >> A >> B;
	if (A + B >= 10)cout << "error";
	else cout << A + B;


Compiler output:
a.cc: In function 'int main()':
a.cc:24:28: error: expected '}' at end of input
   24 |         else cout << A + B;
      |                            ^
a.cc:20:15: note: to match this '{'
   20 | signed main() {
      |               ^
Language: C++

#include <iostream> // cout, endl, cin
#include <iomanip>
#include <string>        // string, to_string, stoi
#include <vector>        // vector
#include <algorithm>     // min, max, swap, sort, reverse, lower_bound, upper_bound
#include <utility>       // pair, make_pair
#include <tuple>         // tuple, make_tuple
#include <cstdint>       // int64_t, int*_t
#include <cstdio>        // printf
#include <map>           // map
#include <queue>         // queue, priority_queue
#include <set>           // set
#include <stack>         // stack
#include <deque>         // deque
#include <unordered_map> // unordered_map
#include <unordered_set> // unordered_set
#include <bitset>        // bitset
#include <cctype>        // isupper, islower, isdigit, toupper, tolower
#include <math.h>
#include <numeric>
using namespace std;
#define _GLIBCXX_DEBUG
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define rep2(i, s, n) for (int i = (s); i < (int)(n); i++)
const int INF = 1001001001;

int main()
{
    int a. b;
    cin >> a >> b;
    if(a + b >= 10)
    {
        cout << "error" <<endl;
    }
    else
    {
        cout << a + b << endl;
    }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:29:10: error: expected initializer before '.' token
   29 |     int a. b;
      |          ^
a.cc:30:12: error: 'a' was not declared in this scope
   30 |     cin >> a >> b;
      |            ^
a.cc:30:17: error: 'b' was not declared in this scope
   30 |     cin >> a >> b;
      |                 ^
Language: C++

#include <iostream>
using namespace std;
int main(void)
{
  int A,B; cin>>A>>B;
  cout<<((A+B)<=9?(A+B):"error")<<endl;

  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:18: error: operands to '?:' have different types 'int' and 'const char*'
    6 |   cout<<((A+B)<=9?(A+B):"error")<<endl;
      |          ~~~~~~~~^~~~~~~~~~~~~~
Language: C++

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

int main(){
  int A,B;
  cin >> A >> B;
  cout << (A + B <= 10 ? A + B : "error") << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:24: error: operands to '?:' have different types 'int' and 'const char*'
    7 |   cout << (A + B <= 10 ? A + B : "error") << endl;
      |            ~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
Language: C

x,y=input().split()

print(int(x)+int(y))

#o mor khoda re... 50 er niche naki charachter run hoyna.. ki jana 

Compiler output:
main.c:1:1: warning: data definition has no type or storage class
    1 | x,y=input().split()
      | ^
main.c:1:1: error: type defaults to 'int' in declaration of 'x' [-Wimplicit-int]
main.c:1:3: error: type defaults to 'int' in declaration of 'y' [-Wimplicit-int]
    1 | x,y=input().split()
      |   ^
main.c:1:5: error: implicit declaration of function 'input' [-Wimplicit-function-declaration]
    1 | x,y=input().split()
      |     ^~~~~
main.c:1:12: error: request for member 'split' in something not a structure or union
    1 | x,y=input().split()
      |            ^
main.c:3:1: error: expected ',' or ';' before 'print'
    3 | print(int(x)+int(y))
      | ^~~~~
main.c:5:2: error: invalid preprocessing directive #o
    5 | #o mor khoda re... 50 er niche naki charachter run hoyna.. ki jana
      |  ^
Language: C++

#include<bits/stdc++.h>
#define REP(i, n) for(int i = 0; i < (int)n; i++)
#define REPvec(itr, mp) for(auto itr = mp.begin();itr != mp.end(); itr ++)
#define all(x) x.begin(), x.end()
#define MOD 1000000007//1e9+7
using namespace std;
typedef long long ll;
typedef vector<int >    vecint;
typedef vector<string > vecstr;
int main()
{
  int a, b;
  cin >> a >> b;
  cout << (((a + b) >= 10)?"error":a+b) << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:14:27: error: operands to '?:' have different types 'const char*' and 'int'
   14 |   cout << (((a + b) >= 10)?"error":a+b) << endl;
      |            ~~~~~~~~~~~~~~~^~~~~~~~~~~~
Language: C++

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



int main() {
	int a,b;
	cin >> a >> b;
	cout << (a+b>=10?"error":a+b) << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:9:25: error: operands to '?:' have different types 'const char*' and 'int'
    9 |         cout << (a+b>=10?"error":a+b) << endl;
      |                  ~~~~~~~^~~~~~~~~~~~
Language: C++

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



int main() {
	int a,b;
	cin >> a >> b;
	cout << ((a+b>=10)?"error":(a+b)) << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:9:27: error: operands to '?:' have different types 'const char*' and 'int'
    9 |         cout << ((a+b>=10)?"error":(a+b)) << endl;
      |                  ~~~~~~~~~^~~~~~~~~~~~~~
Language: C++

A, B = map(int, input().split())
print(A+B if A+B < 10 else 'error')


Compiler output:
a.cc:2:28: warning: multi-character literal with 5 characters exceeds 'int' size of 4 bytes
    2 | print(A+B if A+B < 10 else 'error')
      |                            ^~~~~~~
a.cc:1:1: error: 'A' does not name a type
    1 | A, B = map(int, input().split())
      | ^
Language: C++

#include "bits/stdc++.h"
using namespace std;
#define all(x) (x).begin(), (x).end()
#define rall(x) (x).rbegin(), (x).rend()
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define repr(i, n) for (int i = (int)(n)-1; i >= 0; i--)
#define INF 1e9
using ll = std::int64_t;

template <class T>bool chmax(T &a, const T &b);
template <class T>bool chmin(T &a, const T &b);
//最大公約数
std::int64_t gcd(std::int64_t a, std::int64_t b);
std::int64_t gcd_s(std::int64_t aa, std::int64_t bb);
//ラングレス圧縮
std::vector<std::pair<char, std::int64_t>> rle(std::string str);
//素数判定
bool is_prime(std::int64_t n);
// 約数の列挙
std::vector<std::int64_t> divisor(std::int64_t n);
// 素因数分解
std::map<std::int64_t,std::int64_t> prime_factor(std::int64_t n);

//10^9 + 7
#define yojo 1000000007
#define MAX_NUM 200001

void Main()
{
  int a, b;
  cin >> a >> b;
  std::cout << (a + b >= 10 ? "error" : a + b) << std::endl;

  return;
}

int main()
{
  std::cin.tie(nullptr);
  std::ios_base::sync_with_stdio(false);
  std::cout << std::fixed << std::setprecision(15);
  Main();
  return 0;
}

template <class T> bool chmax(T &a, const T &b)
{
  if (a < b)
  {
    a = b;
    return true;
  }
  return false;
}

template <class T> bool chmin(T &a, const T &b)
{
  if (b < a)
  {
    a = b;
    return true;
  }
  return false;
}

//最大公約数
std::int64_t gcd(std::int64_t a, std::int64_t b)
{
  // a >= b && b != 0
  std::int64_t c;
  do
  {
    c = a % b;
    a = b;
    b = c;
  } while (c);

  return a;
}

//最大公約数安全版
std::int64_t gcd_s(std::int64_t aa, std::int64_t bb)
{
  std::int64_t a = max(aa, bb);
  std::int64_t b = min(aa, bb);
  std::int64_t c;
  if (b == 0)
  {
    return -1;
  }
  do
  {
    c = a % b;
    a = b;
    b = c;
  } while (c);

  return a;
}

//ラングレス圧縮
std::vector<std::pair<char, std::int64_t>> rle(std::string str)
{
  std::vector<std::pair<char, std::int64_t>> data;
  char now = str[0];
  std::int64_t count = 0;
  for (std::int64_t i = 0; i < str.size() + 1; i++)
  {
    if (i == str.size())
    {
      data.push_back(make_pair(str[i - 1], count));
      break;
    }
    else if (now != str[i])
    {
      data.push_back(make_pair(now, count));
      now = str[i];
      count = 0;
    }
    count++;
  }

  return data;
}

//素数判定
bool is_prime(std::int64_t n)
{
  for (std::int64_t i = 0; i * i <= n; i++)
  {
    if (n % i == 0)
    {
      return false;
    }
  }
  
  return n != 1;
}

//約数の列挙
std::vector<std::int64_t> divisor(std::int64_t n)
{
  std::vector<std::int64_t> res;
  for (int i = 0; i < n; i++)
  {
    if(n % i == 0){
      res.push_back(i);
      if (i != n / i) res.push_back(n / i);
    }
  }
  return res;
}

// 素因数分解
std::map<std::int64_t, std::int64_t> prime_factor(std::int64_t n)
{
  std::map<std::int64_t, std::int64_t> res;
  for (int i = 2; i * i <= n; i++)
  {
    while (n % i == 0)
    {
      ++res[i];
      n /= i;
    }
  }

  if (n != 1)
  {
    res[n] = 1;
  }
  
  return res;
}

Compiler output:
a.cc: In function 'void Main()':
a.cc:32:29: error: operands to '?:' have different types 'const char*' and 'int'
   32 |   std::cout << (a + b >= 10 ? "error" : a + b) << std::endl;
      |                 ~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
Language: C++

#include <iostream>
using namespace std;


int main() {
    int a, b;
    cin >> a >> b;
    cout << (a + b >= 10 ? "error" : a + b) << endl;
    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:26: error: operands to '?:' have different types 'const char*' and 'int'
    8 |     cout << (a + b >= 10 ? "error" : a + b) << endl;
      |              ~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
Language: C++

#include <iostream>
#include <cstdio>
#include <cstring>
using namespace std;
int main(){
  int a,b;
  cin>>a>>b;
  cout<<(a+b>=10?"error":a+b);
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:17: error: operands to '?:' have different types 'const char*' and 'int'
    8 |   cout<<(a+b>=10?"error":a+b);
      |          ~~~~~~~^~~~~~~~~~~~
Language: C++

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

int main() {
  int x , y;
  cin >> x >> y;

  cout << (x + y >= 10 ? "error" : x + y) << endl ;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:24: error: operands to '?:' have different types 'const char*' and 'int'
    8 |   cout << (x + y >= 10 ? "error" : x + y) << endl ;
      |            ~~~~~~~~~~~~^~~~~~~~~~~~~~~~~
Language: C++

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

int main() {
  int A, B;
  cin >> A >> B;
  string X = A + B;
  cout << (A+B>10?X:"error") << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:16: error: conversion from 'int' to non-scalar type 'std::string' {aka 'std::__cxx11::basic_string<char>'} requested
    7 |   string X = A + B;
      |              ~~^~~
Language: C++

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

int main() {
  int A, B;
  cin >> A >> B;
  cout << (A+B>10?A+B:"error") << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:18: error: operands to '?:' have different types 'int' and 'const char*'
    7 |   cout << (A+B>10?A+B:"error") << endl;
      |            ~~~~~~^~~~~~~~~~~~
Language: C++

#include <bits/stdc++.h>
#define REP(i, n) for (int i = 0; i < n; i++)
#define REPR(i, n) for (int i = n; i >= 0; i--)
#define FOR(i, m, n) for (int i = m; i < n; i++)
#define ALL(v) v.begin(), v.end()
using namespace std;
typedef long long ll;
typedef long double ld;
int main()
{
  ios::sync_with_stdio(false);
  cin.tie(nullptr);
  int a,b;
  cin >> a >> b;

  cout << (a+b>=10 ? "error" : a+b) << endl;
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:16:20: error: operands to '?:' have different types 'const char*' and 'int'
   16 |   cout << (a+b>=10 ? "error" : a+b) << endl;
      |            ~~~~~~~~^~~~~~~~~~~~~~~
Language: C++

#include<iostream>
using namespace std;
int main(){
int A,B;
cin>>A>>B;
 if (A+B>=10){
   cout <<"error";
   else cout << A+B; 
  
return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:4: error: expected '}' before 'else'
    8 |    else cout << A+B;
      |    ^~~~
a.cc:6:14: note: to match this '{'
    6 |  if (A+B>=10){
      |              ^
Language: C++

#include<iostream>
using namespace std;
int main(){
int A,B;
cin>>A>>B;
  cout << A+B;
 if (A+B>=10){
   cout <<"error";
   else cout << A+B; 
  
return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:9:4: error: expected '}' before 'else'
    9 |    else cout << A+B;
      |    ^~~~
a.cc:7:14: note: to match this '{'
    7 |  if (A+B>=10){
      |              ^
Language: Java

import java.util.*;

class Main {
public static void main(String[] args){

Scenner sc = new Scanner(System.in);
int a = sc.nextInt();
int b = sc.nextInt();
int c = a + b;
if(c <= 9){
System.out.println(c);
}else{
System.out.println("error");
}

}
}

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

#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b;
  cin >> a >> b;
  cout << (a + b >=10 ? "error" : a + b) << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:23: error: operands to '?:' have different types 'const char*' and 'int'
    6 |   cout << (a + b >=10 ? "error" : a + b) << endl;
      |            ~~~~~~~~~~~^~~~~~~~~~~~~~~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
int main() {
  int a, b;
  cin >> a >> b;
  if (a+b < 10)  {
    cout << a+b  << endl;
  } else {
    "error"
  }
  return 0;
}

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

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

int main (){
    int a, b;
    cin>>a>>b;
    if(a+b>9){
      cout<<"error<<endl;
    }
  	else{
      cout<<a+b<<endl;
    }
}

Compiler output:
a.cc:8:13: warning: missing terminating " character
    8 |       cout<<"error<<endl;
      |             ^
a.cc:8:13: error: missing terminating " character
    8 |       cout<<"error<<endl;
      |             ^~~~~~~~~~~~~
a.cc: In function 'int main()':
a.cc:9:5: error: expected primary-expression before '}' token
    9 |     }
      |     ^
Language: C++

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

int main (){
    int a, b;
    cin>>a>>b;
    cout<<(a+b>9?"error":a+b)<<endl;
    
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:17: error: operands to '?:' have different types 'const char*' and 'int'
    7 |     cout<<(a+b>9?"error":a+b)<<endl;
      |            ~~~~~^~~~~~~~~~~~
Language: C++

#include <iostream>

int main(void){
  int x,y;
  
  cin >> x >> y;
  
  if (x + y < 10){
    std::cout << "x + y" << std::endl;
  }
  else{
     std::cout << "error" << std::endl;
  }
  
}


Compiler output:
a.cc: In function 'int main()':
a.cc:6:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    6 |   cin >> x >> y;
      |   ^~~
      |   std::cin
In file included from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){
    int A,B;
    int sum = A+B;
    cout << ((sum >= 10) ? "error" : sum) << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:6:26: error: operands to '?:' have different types 'const char*' and 'int'
    6 |     cout << ((sum >= 10) ? "error" : sum) << endl;
      |              ~~~~~~~~~~~~^~~~~~~~~~~~~~~
Language: C++

#inhclude<stdio.h>
int main(void)
{
	int a,b;
	scanf("%d %d",&a,&b);
	if(a+b>=10)	printf("error\n");
	else	printf("%d",a+b);
	return 0;
}


Compiler output:
a.cc:1:2: error: invalid preprocessing directive #inhclude; did you mean #include?
    1 | #inhclude<stdio.h>
      |  ^~~~~~~~
      |  include
a.cc: In function 'int main()':
a.cc:5:9: error: 'scanf' was not declared in this scope
    5 |         scanf("%d %d",&a,&b);
      |         ^~~~~
a.cc:6:25: error: 'printf' was not declared in this scope
    6 |         if(a+b>=10)     printf("error\n");
      |                         ^~~~~~
a.cc:1:1: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
  +++ |+#include <cstdio>
    1 | #inhclude<stdio.h>
a.cc:7:17: error: 'printf' was not declared in this scope
    7 |         else    printf("%d",a+b);
      |                 ^~~~~~
a.cc:7:17: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
Language: C++

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

const int MOD = 1000000007;
const int INF = 1e9;

//long long
using ll = long long;

//出力系
#define print(x) cout << x << endl
#define yes cout << "Yes" << endl
#define YES cout << "YES" << endl
#define no cout << "No" << endl
#define NO cout << "NO" << endl
 
// begin() end()
#define all(x) (x).begin(),(x).end()

//for
#define REP(i,n) for(int i=0, i##_len=(n); i<i##_len; ++i)
#define REPR(i,n) for(int i=n, i##_len=(n); i>=0; i--)
#define FOR(i,a,b) for(int i=(a), i##_len=(b); i<i##_len; ++i)

//最大公約数 
 ll gcd(ll a,ll b){
 if(b == 0) return a;
 return gcd(b,a%b);
 }

//最小公倍数
 ll lcm(ll a,ll b){
 ll g = gcd(a,b);
 return a / g * b; // Be careful not to overflow  if(a < b) return gcd(b, a);
  unsigned r;
  while ((r=a%b)) {
    a = b;
    b = r;
  }
  return b;
} 




int main() {
int a, b;
cin >> a >> b;
int ans = a + b
if(ans >= 10) print("error");
else print(ans);

}

Compiler output:
a.cc: In function 'int main()':
a.cc:50:1: error: expected ',' or ';' before 'if'
   50 | if(ans >= 10) print("error");
      | ^~
a.cc:51:1: error: 'else' without a previous 'if'
   51 | else print(ans);
      | ^~~~
Language: C++

#include<iostream>
using namespace std;


int main() {

  int a,b; cin >> a >> b ;
  if (a+b) > 9) cout << "error";
  else cout << a+b ; 

}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:12: error: expected primary-expression before '>' token
    8 |   if (a+b) > 9) cout << "error";
      |            ^
Language: C++

#include<iostream>
using namespace std;


int main() {

  int a,b; cin >> a >> b ;
  cout << ((a+b) > 9) ? "error" : a+b << endl;

}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:39: error: invalid operands of types 'int' and '<unresolved overloaded function type>' to binary 'operator<<'
    8 |   cout << ((a+b) > 9) ? "error" : a+b << endl;
      |                                   ~~~~^~~~~~~
Language: C++

#include <iostream>

using namespace std;

int main(){
  int A, B;
  cin >> A >> B;
  
  cout << (A+B < 10)? A+B:"error";


}


Compiler output:
a.cc: In function 'int main()':
a.cc:9:21: error: operands to '?:' have different types 'int' and 'const char*'
    9 |   cout << (A+B < 10)? A+B:"error";
      |   ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~
Language: C++

#include <iosrteam>

using namespace std;

int main(){
  int A, B;
  cin >> A >> B;
  
  cout << A+B < 10? A+B:"error";


}

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

#inslude<iostream>
using namespace std;

int main(){
  int A, B;
  cin >> A >> B;
  if(A+B < 10) cout << A+B;
  else cout << "error";
  return 0;
}

Compiler output:
a.cc:1:2: error: invalid preprocessing directive #inslude; did you mean #include?
    1 | #inslude<iostream>
      |  ^~~~~~~
      |  include
a.cc: In function 'int main()':
a.cc:6:3: error: 'cin' was not declared in this scope
    6 |   cin >> A >> B;
      |   ^~~
a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
  +++ |+#include <iostream>
    1 | #inslude<iostream>
a.cc:7:16: error: 'cout' was not declared in this scope
    7 |   if(A+B < 10) cout << A+B;
      |                ^~~~
a.cc:7:16: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:8:8: error: 'cout' was not declared in this scope
    8 |   else cout << "error";
      |        ^~~~
a.cc:8:8: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
Language: C++

#include <iostream>
#include <cstdlib>
#include <algorithm>
#include <vector>
#include <string>
#include <cmath>
#include <cassert>
#include <functional>
#include <string>
#include <sstream>
using namespace std;


int main(){
  int A, B; cin >> A >> B;
  cout << (A + B < 10 ? A + B : "error") << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:16:23: error: operands to '?:' have different types 'int' and 'const char*'
   16 |   cout << (A + B < 10 ? A + B : "error") << endl;
      |            ~~~~~~~~~~~^~~~~~~~~~~~~~~~~
Language: C++

#include <bits/stdc++.h>
#define REP(i, n) for(ll i = 0; i < (ll)n; i++)
#define FOR(i, a, b) for(ll i = (a); i < (ll)b; i++)
#define ALL(obj) (obj).begin(), (obj).end()
#define INF (1ll << 60)
using namespace std;
typedef long long ll;
typedef double db;
typedef string str;
typedef pair<ll, ll> p;
constexpr int MOD = 1000000007;
using ll = long long;
template <class T> inline bool chmin(T &a, T b) {
    if(a > b) {
        a = b;
        return true;
    }
    return false;
}
template <class T> inline bool chmax(T &a, T b) {
    if(a < b) {
        a = b;
        return true;
    }
    return false;
}

void print(const std::vector<int> &v) {
    std::for_each(v.begin(), v.end(), [](int x) { std::cout << x << " "; });
    std::cout << std::endl;
}

int main() {
    int A, B;
    cin >> A >> B;
    if(A + B >= 10) {
        cout << "error" << endl return 0;
    }
    cout << A + B << endl;
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:37:32: error: expected ';' before 'return'
   37 |         cout << "error" << endl return 0;
      |                                ^~~~~~~
      |                                ;
Language: C++

# -*- coding: utf-8 -*-
import sys
import copy
import collections
from bisect import bisect_left
from bisect import bisect_right
from collections import defaultdict
from heapq import heappop, heappush
import math
import itertools
import random
 
# NO, PAY-PAY
#import numpy as np
#import statistics
#from statistics import mean, median,variance,stdev
 
def inputInt(): return int(input())
def inputMap(): return map(int, input().split())
def inputList(): return list(map(int, input().split()))
 
def main():
    A,B = inputMap()
    
    tmp = A+B
    
    if tmp < 11:
        print(tmp)
    else:
        print("error")
    
        
if __name__ == "__main__":
	main()


Compiler output:
a.cc:1:3: error: invalid preprocessing directive #-
    1 | # -*- coding: utf-8 -*-
      |   ^
a.cc:13:3: error: invalid preprocessing directive #NO
   13 | # NO, PAY-PAY
      |   ^~
a.cc:14:2: warning: #import is a deprecated GCC extension [-Wdeprecated]
   14 | #import numpy as np
      |  ^~~~~~
a.cc:14:9: error: #import expects "FILENAME" or <FILENAME>
   14 | #import numpy as np
      |         ^~~~~
a.cc:15:2: warning: #import is a deprecated GCC extension [-Wdeprecated]
   15 | #import statistics
      |  ^~~~~~
a.cc:15:9: error: #import expects "FILENAME" or <FILENAME>
   15 | #import statistics
      |         ^~~~~~~~~~
a.cc:16:2: error: invalid preprocessing directive #from
   16 | #from statistics import mean, median,variance,stdev
      |  ^~~~
a.cc:2:1: error: 'import' does not name a type
    2 | import sys
      | ^~~~~~
a.cc:2:1: note: C++20 'import' only available with '-fmodules-ts'
Language: C++

#include<bits/stdc++.h>

using namespace std;
typedef long long ll;
typedef pair<ll,ll> P;
#define a first
#define b second
#define sz size()
#define pb(x) push_back(x) 
#define bg begin()
#define ed end()
#define rep(i,n) for(ll i=0;i<n;i++)
#define rep1(i,n) for(ll i=1;i<=n;i++)
#define mp(x,y) make_pair(x,y)
const ll MOD=1000000007;
const ll INF=-10000000000;

ll maxx(ll x,ll y,ll z){
	return max(max(x,y),z);
}
ll minn(ll x,ll y,ll z){
	return min(min(x,y),z);
}
ll gcd(ll x,ll y){
	if(x%y==0) return y;
    else return gcd(y,x%y);
}
ll lcm(ll x,ll y){
	return x*(y/gcd(x,y));
}

//a,b x
int main(){
	ll A,B; cin>>A>>B;
  cout<<(A+B<10?A+B:"error");
      
}

Compiler output:
a.cc: In function 'int main()':
a.cc:35:16: error: operands to '?:' have different types 'll' {aka 'long long int'} and 'const char*'
   35 |   cout<<(A+B<10?A+B:"error");
      |          ~~~~~~^~~~~~~~~~~~