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

#include <iostream>
using namespace std;

int main(){
  int a, b;
  int c[3];
  
  cin >> a >> b;
  c[0] = a + b;
  c[1] = a - b;
  c[2] = a * b;
  
  cout << max(c[0], c[1], c[2]) << endl;
  
  return 0;
}

Compiler output:
In file included from /usr/include/c++/14/string:51,
                 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,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_algobase.h: In instantiation of 'constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare) [with _Tp = int; _Compare = int]':
a.cc:13:14:   required from here
   13 |   cout << max(c[0], c[1], c[2]) << endl;
      |           ~~~^~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/stl_algobase.h:306:17: error: '__comp' cannot be used as a function
  306 |       if (__comp(__a, __b))
      |           ~~~~~~^~~~~~~~~~
Language: C

#include<stdio.h>
#include<stdlib.h>
int max_(int x,int y)
{
  return x>y?x:y;
}
main()
{
  int a,b;
  scanf("%d %d",&a,&b);
  printf("%d",max_(max_(max_(a+b),a*b),a-b));
}

Compiler output:
main.c:7:1: error: return type defaults to 'int' [-Wimplicit-int]
    7 | main()
      | ^~~~
main.c: In function 'main':
main.c:11:25: error: too few arguments to function 'max_'
   11 |   printf("%d",max_(max_(max_(a+b),a*b),a-b));
      |                         ^~~~
main.c:3:5: note: declared here
    3 | int max_(int x,int y)
      |     ^~~~
Language: C++

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

int main(){
    int A, B;
    cin >> A >> B;
    vecter<int> vec;

    
    int X = A + B;
    int Y = A - B;
    int Z = A * B;

    
    vec = {X, Y, Z};

    sort(vec.begin(),vec.end());

    cout << vec.at(3) << endl;

}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:5: error: 'vecter' was not declared in this scope
    7 |     vecter<int> vec;
      |     ^~~~~~
a.cc:7:12: error: expected primary-expression before 'int'
    7 |     vecter<int> vec;
      |            ^~~
a.cc:15:5: error: 'vec' was not declared in this scope
   15 |     vec = {X, Y, Z};
      |     ^~~
Language: C++

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

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

    int X = A + B;
    int Y = A - B;
    int Z = A * B;

    vecter<int> vec;
    vec = {X, Y, Z};

    sort(vec.begin(),vec.end());

    cout << vec.at(3) << endl;

}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:5: error: 'vecter' was not declared in this scope
   12 |     vecter<int> vec;
      |     ^~~~~~
a.cc:12:12: error: expected primary-expression before 'int'
   12 |     vecter<int> vec;
      |            ^~~
a.cc:13:5: error: 'vec' was not declared in this scope
   13 |     vec = {X, Y, Z};
      |     ^~~
Language: C++

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

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

    int X = A + B;
    int Y = A - B;
    int Z = A * B;

    vecter<int> vec(3);
    vec(3) = {X, Y, Z};

    sort(vec.begin(),vec.end());

    cout << vec.at(3) << endl;

}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:5: error: 'vecter' was not declared in this scope
   12 |     vecter<int> vec(3);
      |     ^~~~~~
a.cc:12:12: error: expected primary-expression before 'int'
   12 |     vecter<int> vec(3);
      |            ^~~
a.cc:13:5: error: 'vec' was not declared in this scope
   13 |     vec(3) = {X, Y, Z};
      |     ^~~
Language: C++

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

int main() {
  int A;
  int B;
  cin >> A >> B;
  int a = A + B;
  int b = A - B;
  int c = A * B;
  cout << max(max (a,b)) << endl;
  
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:14: error: no matching function for call to 'max(const int&)'
   11 |   cout << max(max (a,b)) << endl;
      |           ~~~^~~~~~~~~~~
In file included from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_algobase.h:257:5: note: candidate: 'template<class _Tp> constexpr const _Tp& std::max(const _Tp&, const _Tp&)'
  257 |     max(const _Tp& __a, const _Tp& __b)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:257:5: note:   candidate expects 2 arguments, 1 provided
/usr/include/c++/14/bits/stl_algobase.h:303:5: note: candidate: 'template<class _Tp, class _Compare> constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare)'
  303 |     max(const _Tp& __a, const _Tp& __b, _Compare __comp)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:303:5: note:   candidate expects 3 arguments, 1 provided
In file included from /usr/include/c++/14/algorithm:61:
/usr/include/c++/14/bits/stl_algo.h:5706:5: note: candidate: 'template<class _Tp> constexpr _Tp std::max(initializer_list<_Tp>)'
 5706 |     max(initializer_list<_Tp> __l)
      |     ^~~
/usr/include/c++/14/bits/stl_algo.h:5706:5: note:   template argument deduction/substitution failed:
a.cc:11:14: note:   mismatched types 'std::initializer_list<_Tp>' and 'int'
   11 |   cout << max(max (a,b)) << endl;
      |           ~~~^~~~~~~~~~~
/usr/include/c++/14/bits/stl_algo.h:5716:5: note: candidate: 'template<class _Tp, class _Compare> constexpr _Tp std::max(initializer_list<_Tp>, _Compare)'
 5716 |     max(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
/usr/include/c++/14/bits/stl_algo.h:5716:5: note:   candidate expects 2 arguments, 1 provided
Language: C++

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

int main() {
  int A;
  int B;
  cin >> A >> B;
  int a = A + B;
  int b = A - B;
  int c = A * B;
  cout << max (a,b,c) << endl;
  
}

Compiler output:
In file included from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_algobase.h: In instantiation of 'constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare) [with _Tp = int; _Compare = int]':
a.cc:11:15:   required from here
   11 |   cout << max (a,b,c) << endl;
      |           ~~~~^~~~~~~
/usr/include/c++/14/bits/stl_algobase.h:306:17: error: '__comp' cannot be used as a function
  306 |       if (__comp(__a, __b))
      |           ~~~~~~^~~~~~~~~~
Language: C++

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

int main() {
  int  A,B;
  cin >> A >> B;
  int a = A + B;
  int b = A - B;
  int c = A * B;
  cout << max (a,b,c) << endl;
  
}

Compiler output:
In file included from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_algobase.h: In instantiation of 'constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare) [with _Tp = int; _Compare = int]':
a.cc:10:15:   required from here
   10 |   cout << max (a,b,c) << endl;
      |           ~~~~^~~~~~~
/usr/include/c++/14/bits/stl_algobase.h:306:17: error: '__comp' cannot be used as a function
  306 |       if (__comp(__a, __b))
      |           ~~~~~~^~~~~~~~~~
Language: C++

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

int main() {
  int  A,B;
  cin >> A >> B;
  a = A + B;
  b = A - B;
  c = A * B;
  cout << max (a,b,c) << endl;
  
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:3: error: 'a' was not declared in this scope
    7 |   a = A + B;
      |   ^
a.cc:8:3: error: 'b' was not declared in this scope
    8 |   b = A - B;
      |   ^
a.cc:9:3: error: 'c' was not declared in this scope
    9 |   c = A * B;
      |   ^
Language: C++

#include<stdio.h>
using namespace std;
int main(){
  int a, b ;  cin >> a>> b ;
  int add = a+b , sub = a-b ,mul =a*b ;
  cout << max(add , max(sub , mul)) ;
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:4:15: error: 'cin' was not declared in this scope
    4 |   int a, b ;  cin >> a>> b ;
      |               ^~~
a.cc:2:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
    1 | #include<stdio.h>
  +++ |+#include <iostream>
    2 | using namespace std;
a.cc:6:3: error: 'cout' was not declared in this scope
    6 |   cout << max(add , max(sub , mul)) ;
      |   ^~~~
a.cc:6:3: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:6:21: error: 'max' was not declared in this scope
    6 |   cout << max(add , max(sub , mul)) ;
      |                     ^~~
a.cc:6:11: error: 'max' was not declared in this scope
    6 |   cout << max(add , max(sub , mul)) ;
      |           ^~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
 
int main(){
  int a,b;
  cin >> a >> b;
  cout << max(a+b,max(a-b,a*b))
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:32: error: expected ';' before 'return'
    7 |   cout << max(a+b,max(a-b,a*b))
      |                                ^
      |                                ;
    8 |   return 0;
      |   ~~~~~~
Language: C++

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

int main(){
  int a,b;
  cin >> a >> b;
  cout << max(a+b,max(a-b.a*b))
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:27: error: request for member 'a' in 'b', which is of non-class type 'int'
    7 |   cout << max(a+b,max(a-b.a*b))
      |                           ^
Language: Java

package app;

import java.util.Scanner;

public class App {
    public static void main(String[] args) throws Exception {

        Scanner sc = new Scanner(System.in);

        int aNum = sc.nextInt();
        int bNum = sc.nextInt();

        sc.close();

        int tasizan = aNum + bNum;
        int hikizan = aNum - bNum;
        int kakezan = aNum * bNum;

        int max = tasizan;
        if (max <= hikizan) {
            max = hikizan;
        }
        if (max <= kakezan) {
            max = kakezan;
        }

        System.out.println(max);
    }
}

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

#include <stdio.h>
dio.h>
int main(void)
{
  int A,B,C,D,E;
  scanf("%d%d",&A,&B);
  
  C=A+B;
  D=A-B;
  E=A*B;
  
  if(C > D && C > E){
    printf("%d",C);
    }else if (D > C && D > E){
    printf("%d",D);
    }else if(E > C && E > D){
    printf("%d",E);
    }
  return 0;
}

Compiler output:
main.c:2:4: error: expected '=', ',', ';', 'asm' or '__attribute__' before '.' token
    2 | dio.h>
      |    ^
Language: C

#include <st#include <stdio.h>
dio.h>
int main(void)
{
  int A,B,C,D,E;
  scanf("%d%d",&A,&B);
  
  C=A+B;
  D=A-B;
  E=A*B;
  
  if(C > D && C > E){
    printf("%d",C);
    }else if (D > C && D > E){
    printf("%d",D);
    }else if(E > C && E > D){
    printf("%d",E);
    }
  return 0;
}

Compiler output:
main.c:1:10: fatal error: st#include <stdio.h: No such file or directory
    1 | #include <st#include <stdio.h>
      |          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Language: Java

import java.util.Scanner;

public class ABC137A {

	public static void main(String[] args) {
		Scanner s = new Scanner(System.in);
		int a = s.nextInt();
		int b = s.nextInt();
		int ans = Math.max(Math.max(a+b, a-b),a*b);
		System.out.println(ans);

	}

}


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

#include<stdio.h>
int main(){
  int A,B,p,k,w.h;
  scanf("%d %d",&A,&B);
  p = A+B;
  k= A*B;
  w=A-B;
  if(p > k)h=p;
  else h= k;
  if(h>w)h=h;
  else h=w;
  printf("%d",h);
}
  

Compiler output:
a.cc: In function 'int main()':
a.cc:3:16: error: expected initializer before '.' token
    3 |   int A,B,p,k,w.h;
      |                ^
a.cc:7:3: error: 'w' was not declared in this scope
    7 |   w=A-B;
      |   ^
a.cc:8:12: error: 'h' was not declared in this scope
    8 |   if(p > k)h=p;
      |            ^
a.cc:9:8: error: 'h' was not declared in this scope
    9 |   else h= k;
      |        ^
a.cc:10:6: error: 'h' was not declared in this scope
   10 |   if(h>w)h=h;
      |      ^
a.cc:12:15: error: 'h' was not declared in this scope
   12 |   printf("%d",h);
      |               ^
Language: C++

#include<stadio.h>
int main(){
  int A,B,p,k,w.h;
  scanf("%d %d",&A,&B)
  p = A+B;
  k= A*B;
  w=A-B;
  if(p > k)h=p;
  else h= k;
  if(h>w)h=h;
  else h=w;
  printf("%d",h)
}
  

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

#include <bits/stdc++.h>
#include<cmath> 

#define fastio ios_base::sync_with_stdio(false); cin.tie(NULL);
#define SUBL freopen("/home/ajinkya/Desktop/input.txt","r",stdin); freopen("/home/ajinkya/Desktop/output.txt","w",stdout); 
#define ll long long
#define ull unsigned long long
#define FI(i,a,n) for(int i=a; i<=n; i++)
#define RFI(i,n,a) for(int i=n; i>=a; i--)
#define FLL(i,a,n) for(ll i=a; i<=n; i++)
#define RFLL(i,n,a) for(ll i=n; i>=a; i--)
#define vi vector<int>
#define vll vector<ll>
#define all(v) v.begin(),v.end()
#define pll pair<ll,ll>
#define pi pair<int, int>
#define GCD(a,b) __gcd(a,b)
#define MP make_pair
#define PB push_back
#define PF push_front
#define LB lower_bound
#define UB upper_bound
#define debug(x) cout << x << endl
#define MOD 1000000007
#define INF LLONG_MAX
#define PI 3.14159265359
using namespace std;




int main()
{
    fastio 
    // SUBL
  	cin >> a >> b;
  	cout << max(a+b,max(a-b,a*b));
    return 0;
}         	

Compiler output:
a.cc: In function 'int main()':
a.cc:36:16: error: 'a' was not declared in this scope
   36 |         cin >> a >> b;
      |                ^
a.cc:36:21: error: 'b' was not declared in this scope
   36 |         cin >> a >> b;
      |                     ^
Language: Java

import java.util.Scanner;

private static void main(String[] args) {
  Scanner scan = new Scanner(System.in);
  
  int a = scan.nextInt(), b = scan.nextInt();
  
  System.out.println(Math.max(a + b, Math.max(a - b, a * b)));
}

Compiler output:
Main.java:3: error: unnamed classes are a preview feature and are disabled by default.
private static void main(String[] args) {
               ^
  (use --enable-preview to enable unnamed classes)
1 error
Language: Java

import java.util.*;
import java.io.*;

public class Solution
{
  public static void main(String[] args) throws IOException
  {
     BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
     StringTokenizer tokenizer1 = new StringTokenizer(br.readLine());
     int a = Integer.parseInt(tokenizer1.nextToken());
     int b = Integer.parseInt(tokenizer1.nextToken());
     int ans = maximum(a,b);
     System.out.println(ans);
  }
  public static int maximum(int a,int b)
  {
    int x = a + b;
    int y = a - b;
    int z = a * b;
    
    int ans1 = Math.max(x,y);
    int ans = Math.max(ans1,z);
    return ans;
  }
}

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

#include<stdio.h>
include<stdlib.h>
int main(int argc, char **argv) {
  int a, b;
  a = atoi(argv[1]);
  b = atoi(argv[2]);
  int c,d,e;
  c = a + b;
  d = c;
  printf("A + B = %d, ", c);
  c = a - b;
  if(c > d) {d = c;}
  printf("A + B = %d, ", c);
  c = a * b;
  if(c > d) {d = c;}
  printf("A + B = %dの中で最大の数は%dです。\n", c, d);
  return 0;
}

Compiler output:
main.c:2:8: error: expected '=', ',', ';', 'asm' or '__attribute__' before '<' token
    2 | include<stdlib.h>
      |        ^
Language: C

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

int main(){
  int A,B;
  int x,y,z,max;
  
  cin >> A;
  cin >> B;
  
  x = A + B;
  y = A - B;
  z = A * B;
  
  max = x;
  if(max < y){
    max = y;
  } else if(max < z){
    max = z;
  }
  
  cout << max << endl;
}

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

#include<bits/stdc++.h>
using namespace std;
int main()
{
  int a,b;
  cin>>a>>b;
  int s=a+b,d=a-b,m=a*b;
  if(s>d && s>m)cout<<s<<"\n;
    else if(d>s && d>m)cout<<d<<"\n;
      else cout<<m<<"\n;
  return 0;
}

Compiler output:
a.cc:8:26: warning: missing terminating " character
    8 |   if(s>d && s>m)cout<<s<<"\n;
      |                          ^
a.cc:8:26: error: missing terminating " character
    8 |   if(s>d && s>m)cout<<s<<"\n;
      |                          ^~~~
a.cc:9:33: warning: missing terminating " character
    9 |     else if(d>s && d>m)cout<<d<<"\n;
      |                                 ^
a.cc:9:33: error: missing terminating " character
    9 |     else if(d>s && d>m)cout<<d<<"\n;
      |                                 ^~~~
a.cc:10:21: warning: missing terminating " character
   10 |       else cout<<m<<"\n;
      |                     ^
a.cc:10:21: error: missing terminating " character
   10 |       else cout<<m<<"\n;
      |                     ^~~~
a.cc: In function 'int main()':
a.cc:9:5: error: expected primary-expression before 'else'
    9 |     else if(d>s && d>m)cout<<d<<"\n;
      |     ^~~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{
  int a,b;
  cin>>a>>b;
  if(a>0 && b>0)cout<<a*b<<"\n";
    else if(a=>0 && b<=0)cout<<a+b<<"\n";
      else cout<<a-b<<"\n";
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:15: error: expected primary-expression before '>' token
    8 |     else if(a=>0 && b<=0)cout<<a+b<<"\n";
      |               ^
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{
  int a,b;
  if(a>0 && b>0)cout<<a*b<<"\n;
    else if(a=>0 && b<=0)cout<<a+b<<"\n;
      else cout<<a-b<<"\n;
  return 0;
}

Compiler output:
a.cc:6:28: warning: missing terminating " character
    6 |   if(a>0 && b>0)cout<<a*b<<"\n;
      |                            ^
a.cc:6:28: error: missing terminating " character
    6 |   if(a>0 && b>0)cout<<a*b<<"\n;
      |                            ^~~~
a.cc:7:37: warning: missing terminating " character
    7 |     else if(a=>0 && b<=0)cout<<a+b<<"\n;
      |                                     ^
a.cc:7:37: error: missing terminating " character
    7 |     else if(a=>0 && b<=0)cout<<a+b<<"\n;
      |                                     ^~~~
a.cc:8:23: warning: missing terminating " character
    8 |       else cout<<a-b<<"\n;
      |                       ^
a.cc:8:23: error: missing terminating " character
    8 |       else cout<<a-b<<"\n;
      |                       ^~~~
a.cc: In function 'int main()':
a.cc:7:5: error: expected primary-expression before 'else'
    7 |     else if(a=>0 && b<=0)cout<<a+b<<"\n;
      |     ^~~~
Language: C++

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

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

    int X = A + B;
    int Y = A - B;
    int Z = A * B;

    vecter<int> vec(3);
    vec(3) = {X, Y, Z};

    sort(vec.begin(),vec.end());

    cout << vec.at(3) << endl;

}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:12: error: 'A' was not declared in this scope
    5 |     cin >> A >> B;
      |            ^
a.cc:5:17: error: 'B' was not declared in this scope
    5 |     cin >> A >> B;
      |                 ^
a.cc:11:5: error: 'vecter' was not declared in this scope
   11 |     vecter<int> vec(3);
      |     ^~~~~~
a.cc:11:12: error: expected primary-expression before 'int'
   11 |     vecter<int> vec(3);
      |            ^~~
a.cc:12:5: error: 'vec' was not declared in this scope
   12 |     vec(3) = {X, Y, Z};
      |     ^~~
Language: C++

#include <bits/stdc++.h>

using namespace std;

int main()
{
  int a,b;
  cin >> a >> b;
  cout << max(a+b, a-b, a*b) << endl;
}

Compiler output:
In file included from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_algobase.h: In instantiation of 'constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare) [with _Tp = int; _Compare = int]':
a.cc:9:14:   required from here
    9 |   cout << max(a+b, a-b, a*b) << endl;
      |           ~~~^~~~~~~~~~~~~~~
/usr/include/c++/14/bits/stl_algobase.h:306:17: error: '__comp' cannot be used as a function
  306 |       if (__comp(__a, __b))
      |           ~~~~~~^~~~~~~~~~
Language: C++

#include <bits/stdc++.h>

using name space std;

int main()
{
  int a, b;
  cin >> a >> b;
  cout << max(a+b, a-b, a*b) << endl;
}

Compiler output:
a.cc:3:7: error: expected nested-name-specifier before 'name'
    3 | using name space std;
      |       ^~~~
a.cc: In function 'int main()':
a.cc:8:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    8 |   cin >> a >> b;
      |   ^~~
      |   std::cin
In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:146,
                 from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:9:3: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    9 |   cout << max(a+b, a-b, a*b) << 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:9:11: error: 'max' was not declared in this scope; did you mean 'std::max'?
    9 |   cout << max(a+b, a-b, a*b) << endl;
      |           ^~~
      |           std::max
In file included from /usr/include/c++/14/algorithm:61,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51:
/usr/include/c++/14/bits/stl_algo.h:5716:5: note: 'std::max' declared here
 5716 |     max(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
a.cc:9:33: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
    9 |   cout << max(a+b, a-b, a*b) << endl;
      |                                 ^~~~
      |                                 std::endl
In file included from /usr/include/c++/14/istream:41,
                 from /usr/include/c++/14/sstream:40,
                 from /usr/include/c++/14/complex:45,
                 from /usr/include/c++/14/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:127:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
Language: C++

#include <iostream>

int main() {

  int A, B;
  std::cin >> A >> B;

  int result = std::max({A+B, A-B, A*B});
  std::cout << result << std::endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:24: error: no matching function for call to 'max(<brace-enclosed initializer list>)'
    8 |   int result = std::max({A+B, A-B, A*B});
      |                ~~~~~~~~^~~~~~~~~~~~~~~~~
In file included from /usr/include/c++/14/string:51,
                 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,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_algobase.h:257:5: note: candidate: 'template<class _Tp> constexpr const _Tp& std::max(const _Tp&, const _Tp&)'
  257 |     max(const _Tp& __a, const _Tp& __b)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:257:5: note:   candidate expects 2 arguments, 1 provided
/usr/include/c++/14/bits/stl_algobase.h:303:5: note: candidate: 'template<class _Tp, class _Compare> constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare)'
  303 |     max(const _Tp& __a, const _Tp& __b, _Compare __comp)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:303:5: note:   candidate expects 3 arguments, 1 provided
Language: C++

#include<iostream>
#include<math.h>
using namespace std;
int main(){
  int a,b;
  cin>>a>>b;
  cout<<max({a+b,a-b,a*b})<<endl;
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:12: error: no matching function for call to 'max(<brace-enclosed initializer list>)'
    7 |   cout<<max({a+b,a-b,a*b})<<endl;
      |         ~~~^~~~~~~~~~~~~~~
In file included from /usr/include/c++/14/string:51,
                 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,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_algobase.h:257:5: note: candidate: 'template<class _Tp> constexpr const _Tp& std::max(const _Tp&, const _Tp&)'
  257 |     max(const _Tp& __a, const _Tp& __b)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:257:5: note:   candidate expects 2 arguments, 1 provided
/usr/include/c++/14/bits/stl_algobase.h:303:5: note: candidate: 'template<class _Tp, class _Compare> constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare)'
  303 |     max(const _Tp& __a, const _Tp& __b, _Compare __comp)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:303:5: note:   candidate expects 3 arguments, 1 provided
Language: C++

#include <bits/stdc++.h>
#define repd(i,a,b) for (int i=(a);i<(b);i++)
#define rep(i,n) repd(i,0,n)
#define int long long
typedef long long ll;
const int MOD = 1000000007;
const int INF = 1010000000;
const double EPS = 1e-10;
using namespace std;

signed main() {
  int a,b;cin>>a>>b;
  cout << max(a+b, a-b, a*b) << endl;
}



Compiler output:
In file included from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_algobase.h: In instantiation of 'constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare) [with _Tp = long long int; _Compare = long long int]':
a.cc:13:14:   required from here
   13 |   cout << max(a+b, a-b, a*b) << endl;
      |           ~~~^~~~~~~~~~~~~~~
/usr/include/c++/14/bits/stl_algobase.h:306:17: error: '__comp' cannot be used as a function
  306 |       if (__comp(__a, __b))
      |           ~~~~~~^~~~~~~~~~
Language: C++

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

int main(){
	int a,b;
  cin >> a >> b ;
  
  int max = 0;
  
  if ( (a+b) >= (a-b) )
    max = a+b ;
  else
    max = a-b ;
  
  if ( max >= a*b )
    cout << max ;
  else 
    cout << a*b ;


}

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

#include <iostream>
using namespace std;
int main(){
  int a,b;
  cin >> a >> b;
  cout << max({a+b,a-b,a*b}) << endl;
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:14: error: no matching function for call to 'max(<brace-enclosed initializer list>)'
    6 |   cout << max({a+b,a-b,a*b}) << endl;
      |           ~~~^~~~~~~~~~~~~~~
In file included from /usr/include/c++/14/string:51,
                 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,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_algobase.h:257:5: note: candidate: 'template<class _Tp> constexpr const _Tp& std::max(const _Tp&, const _Tp&)'
  257 |     max(const _Tp& __a, const _Tp& __b)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:257:5: note:   candidate expects 2 arguments, 1 provided
/usr/include/c++/14/bits/stl_algobase.h:303:5: note: candidate: 'template<class _Tp, class _Compare> constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare)'
  303 |     max(const _Tp& __a, const _Tp& __b, _Compare __comp)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:303:5: note:   candidate expects 3 arguments, 1 provided
Language: Java

import java.util.*;
public class Past1{
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		//整数の入力
		int A = sc.nextInt();
		int B = sc.nextInt();
		//計算
		int a = A + B;
		int b = A - B;
		int c = A * B;
		
		if (a > b && a > c){
			System.out.println(a);
		}
		else if (b > c){
			System.out.println(b);
		}
		else {
			System.out.println(c);
		}
	}
}

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

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

int main()
{
	int A, B;
	int max;
	cin >> A >> B;
	int a1, a2, a3, max;
	
	a1 = A + B;
	a3 = A * B;

	if (B < 0) {
		a2 = A - (B);
	}
	else {
		a2 = A - B;
	}
	
	if (a1 > a2) {
		if (a1 > a3) {
			max = a1;
		}
	}
	else if (a2 > a3) {
		max = a2;
		
	}
	else {
		max = a3;
	}

	cout << max;
	
	

}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:25: error: redeclaration of 'int max'
    9 |         int a1, a2, a3, max;
      |                         ^~~
a.cc:7:13: note: 'int max' previously declared here
    7 |         int max;
      |             ^~~
Language: C

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


Compiler output:
main.c: In function 'main':
main.c:8:33: error: expected ';' before 'printf'
    8 |     else(a*b > a+b && a*b > a-b) printf("%d\n",a*b);
      |                                 ^~~~~~~
      |                                 ;
Language: C++

#include <iostream>
#include <algorithm>
#include <numeric>
#include <vector>
#include <list>
#include <queue>
#include <string>
#include <map>
using namespace std;

int main()
{
    int A,B;
    cin>>A>>B;
    cout<<max(A+B,A-B,A*B)<<endl;
    return 0;
}
/* 注意すべき点
グローバル以外の配列は初期化すべし
*/

Compiler output:
In file included from /usr/include/c++/14/string:51,
                 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,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_algobase.h: In instantiation of 'constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare) [with _Tp = int; _Compare = int]':
a.cc:15:14:   required from here
   15 |     cout<<max(A+B,A-B,A*B)<<endl;
      |           ~~~^~~~~~~~~~~~~
/usr/include/c++/14/bits/stl_algobase.h:306:17: error: '__comp' cannot be used as a function
  306 |       if (__comp(__a, __b))
      |           ~~~~~~^~~~~~~~~~
Language: C

#include<stdio.h>
int main(void)
{
  int A,B;
  scanf("%d%d",&A,&B);
  if(A>=2&&B>=2)
    printf("%d\n",A*B);
  else if(B>=0)
    printf;("%d\n",A+B);
  else if(A<=-1)
    printf("%d\n",A*B);
  else
    printf("%d\n",A-B);
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:10:3: error: 'else' without a previous 'if'
   10 |   else if(A<=-1)
      |   ^~~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){
  int N , M;
  cin >> N >> M;
  int a = N+M;
  int b = N-M;
  int c = N*M;
  cout << max(a,b,c) << endl;
}


Compiler output:
In file included from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_algobase.h: In instantiation of 'constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare) [with _Tp = int; _Compare = int]':
a.cc:9:14:   required from here
    9 |   cout << max(a,b,c) << endl;
      |           ~~~^~~~~~~
/usr/include/c++/14/bits/stl_algobase.h:306:17: error: '__comp' cannot be used as a function
  306 |       if (__comp(__a, __b))
      |           ~~~~~~^~~~~~~~~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){
  int N , M;
  cin >> N >> M;
  int a = N + M;
  int b = N - M;
  int c = N * M;
  cout << max(a,b,c) <<endl;
}


Compiler output:
In file included from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_algobase.h: In instantiation of 'constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare) [with _Tp = int; _Compare = int]':
a.cc:9:14:   required from here
    9 |   cout << max(a,b,c) <<endl;
      |           ~~~^~~~~~~
/usr/include/c++/14/bits/stl_algobase.h:306:17: error: '__comp' cannot be used as a function
  306 |       if (__comp(__a, __b))
      |           ~~~~~~^~~~~~~~~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){
  int N,M;
  cin >> N >> M;
  int a = N + M;
  int b = N - M;
  int c = N * M;
  int answer = max(a,b,c);
  cout << answer <<endl;
}


Compiler output:
In file included from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_algobase.h: In instantiation of 'constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare) [with _Tp = int; _Compare = int]':
a.cc:9:19:   required from here
    9 |   int answer = max(a,b,c);
      |                ~~~^~~~~~~
/usr/include/c++/14/bits/stl_algobase.h:306:17: error: '__comp' cannot be used as a function
  306 |       if (__comp(__a, __b))
      |           ~~~~~~^~~~~~~~~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){
  int N,M;
  cin >> N >> M;
  int a = N + M;
  int b = N - M;
  int c = N * M;
  int answer = max(a,b,c);
  cout << answer <<endl;
}

Compiler output:
In file included from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_algobase.h: In instantiation of 'constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare) [with _Tp = int; _Compare = int]':
a.cc:9:19:   required from here
    9 |   int answer = max(a,b,c);
      |                ~~~^~~~~~~
/usr/include/c++/14/bits/stl_algobase.h:306:17: error: '__comp' cannot be used as a function
  306 |       if (__comp(__a, __b))
      |           ~~~~~~^~~~~~~~~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){
  int N,M;
  cin >> N >> M;
  int a = N + M;
  int b = N - M;
  int c = N * M;
  cout << max(a,b,c) <<endl;
}

Compiler output:
In file included from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_algobase.h: In instantiation of 'constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare) [with _Tp = int; _Compare = int]':
a.cc:9:14:   required from here
    9 |   cout << max(a,b,c) <<endl;
      |           ~~~^~~~~~~
/usr/include/c++/14/bits/stl_algobase.h:306:17: error: '__comp' cannot be used as a function
  306 |       if (__comp(__a, __b))
      |           ~~~~~~^~~~~~~~~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){
  int N,M;
  cin >> N >> M;
  int a,b,c;
  a = N + M;
  b = N - M;
  c = N * M;
  cout << max(a,b,c) <<endl;
}

Compiler output:
In file included from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_algobase.h: In instantiation of 'constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare) [with _Tp = int; _Compare = int]':
a.cc:10:14:   required from here
   10 |   cout << max(a,b,c) <<endl;
      |           ~~~^~~~~~~
/usr/include/c++/14/bits/stl_algobase.h:306:17: error: '__comp' cannot be used as a function
  306 |       if (__comp(__a, __b))
      |           ~~~~~~^~~~~~~~~~
Language: C++

#include <cstdio>
using namespace std;
int a, b;
int main() {
	scanf("%d %d", &a, &b);
  	printf("%d", max(max(a - b, a + b), a * b));
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:26: error: 'max' was not declared in this scope
    6 |         printf("%d", max(max(a - b, a + b), a * b));
      |                          ^~~
a.cc:6:22: error: 'max' was not declared in this scope
    6 |         printf("%d", max(max(a - b, a + b), a * b));
      |                      ^~~
Language: C++

using System;
using System.Linq;

namespace A
{
    class Program
    {
        static void Main(string[] args)
        {
            int[] input = Console.ReadLine().Split().Select(i => Convert.ToInt32(i)).ToArray();
            int add = input[0] + input[1];
            int sub = input[0] - input[1];
            int mul = input[0] * input[1];
            Console.WriteLine(Math.Max(Math.Max(add, sub), mul));
        }
    }
}


Compiler output:
a.cc:1:7: error: expected nested-name-specifier before 'System'
    1 | using System;
      |       ^~~~~~
a.cc:2:7: error: expected nested-name-specifier before 'System'
    2 | using System.Linq;
      |       ^~~~~~
a.cc:8:26: error: 'string' has not been declared
    8 |         static void Main(string[] args)
      |                          ^~~~~~
a.cc:8:35: error: expected ',' or '...' before 'args'
    8 |         static void Main(string[] args)
      |                                   ^~~~
a.cc:16:6: error: expected ';' after class definition
   16 |     }
      |      ^
      |      ;
a.cc: In static member function 'static void A::Program::Main(int*)':
a.cc:10:16: error: structured binding declaration cannot have type 'int'
   10 |             int[] input = Console.ReadLine().Split().Select(i => Convert.ToInt32(i)).ToArray();
      |                ^~
a.cc:10:16: note: type must be cv-qualified 'auto' or reference to cv-qualified 'auto'
a.cc:10:16: error: empty structured binding declaration
a.cc:10:19: error: expected initializer before 'input'
   10 |             int[] input = Console.ReadLine().Split().Select(i => Convert.ToInt32(i)).ToArray();
      |                   ^~~~~
a.cc:11:23: error: 'input' was not declared in this scope; did you mean 'int'?
   11 |             int add = input[0] + input[1];
      |                       ^~~~~
      |                       int
a.cc:14:13: error: 'Console' was not declared in this scope
   14 |             Console.WriteLine(Math.Max(Math.Max(add, sub), mul));
      |             ^~~~~~~
a.cc:14:31: error: 'Math' was not declared in this scope
   14 |             Console.WriteLine(Math.Max(Math.Max(add, sub), mul));
      |                               ^~~~
Language: C

#include<stdio.h>
int main(void){
  int a=101,b=101,max;
  while(!(-100<=a&&a<=100&&-100<=b&&b<=100){
  	scanf("%d %d",&a,&b);
  }
  max=a+b;
  if(max<a-b){
    max=a-b;
  }else if(max<a*b){
    max=a*b;
  }
  printf("%d\n",max);
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:4:44: error: expected ')' before '{' token
    4 |   while(!(-100<=a&&a<=100&&-100<=b&&b<=100){
      |        ~                                   ^
      |                                            )
main.c:15:1: error: expected expression before '}' token
   15 | }
      | ^
Language: C++

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

int main(){
    int a, b, c;
    cin >> a >> b;
    cout << max(a + b, a - b, a * b);
}


Compiler output:
In file included from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_algobase.h: In instantiation of 'constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare) [with _Tp = int; _Compare = int]':
a.cc:8:16:   required from here
    8 |     cout << max(a + b, a - b, a * b);
      |             ~~~^~~~~~~~~~~~~~~~~~~~~
/usr/include/c++/14/bits/stl_algobase.h:306:17: error: '__comp' cannot be used as a function
  306 |       if (__comp(__a, __b))
      |           ~~~~~~^~~~~~~~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main(){
  int A, B;
  cin >>A>>B;
  int a,b,c;
  a=A+B;
  b=A-B;
  c=A*B;
  int ans=max(a,b,c);
  cout <<ans<<endl;
}

Compiler output:
In file included from /usr/include/c++/14/algorithm:60,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:51,
                 from a.cc:1:
/usr/include/c++/14/bits/stl_algobase.h: In instantiation of 'constexpr const _Tp& std::max(const _Tp&, const _Tp&, _Compare) [with _Tp = int; _Compare = int]':
a.cc:10:14:   required from here
   10 |   int ans=max(a,b,c);
      |           ~~~^~~~~~~
/usr/include/c++/14/bits/stl_algobase.h:306:17: error: '__comp' cannot be used as a function
  306 |       if (__comp(__a, __b))
      |           ~~~~~~^~~~~~~~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main(){
  int A, B;
  cin >>A>>B;
  int a,b,c;
  a=A+B;
  b=A-B;
  c=A*B;
  int ans==max(a,b,c);
  cout <<ans<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:10: error: expected initializer before '==' token
   10 |   int ans==max(a,b,c);
      |          ^~
a.cc:11:10: error: 'ans' was not declared in this scope; did you mean 'abs'?
   11 |   cout <<ans<<endl;
      |          ^~~
      |          abs
Language: C++

#include<iostream>
using namespace std;
int main()
{
  int a,b;
  cin>>a>>b;
  cout<<max(max(a+b,a-b),a*b)<<endl;
  retrun 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:3: error: 'retrun' was not declared in this scope
    8 |   retrun 0;
      |   ^~~~~~
Language: Java


import java.util.Scanner;


public class test2 {

    public static void main(String args[])
    {
        Scanner sc=new Scanner(System.in);
        int a=sc.nextInt();
        int b=sc.nextInt();
        int c=a*b;
        int d=a+b;
        int e=a-b;
        if(c>=d && c>=e)
        {
            System.out.println(c);
        }
        else if(d>=c && d>=e)
        {
            System.out.println(d);
        }
        else
        {
            System.out.println(e);
        }
    }
}


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

#include<iostream>
#using namespace std;
int main(){
	int A,B;
  	cin >>A >> B;
  	cout << max(max(A-B,A+B),A*B);
  	return 0;
}

Compiler output:
a.cc:2:2: error: invalid preprocessing directive #using
    2 | #using namespace std;
      |  ^~~~~
a.cc: In function 'int main()':
a.cc:5:9: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    5 |         cin >>A >> B;
      |         ^~~
      |         std::cin
In file included from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:6:9: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    6 |         cout << max(max(A-B,A+B),A*B);
      |         ^~~~
      |         std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:6:21: error: 'max' was not declared in this scope; did you mean 'std::max'?
    6 |         cout << max(max(A-B,A+B),A*B);
      |                     ^~~
      |                     std::max
In file included from /usr/include/c++/14/string:51,
                 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,
                 from /usr/include/c++/14/ostream:40,
                 from /usr/include/c++/14/iostream:41:
/usr/include/c++/14/bits/stl_algobase.h:303:5: note: 'std::max' declared here
  303 |     max(const _Tp& __a, const _Tp& __b, _Compare __comp)
      |     ^~~
a.cc:6:17: error: 'max' was not declared in this scope; did you mean 'std::max'?
    6 |         cout << max(max(A-B,A+B),A*B);
      |                 ^~~
      |                 std::max
/usr/include/c++/14/bits/stl_algobase.h:303:5: note: 'std::max' declared here
  303 |     max(const _Tp& __a, const _Tp& __b, _Compare __comp)
      |     ^~~
Language: C

#include<stdio.h>
  int main(void){
    int a,b,sum,sub,pro;
    scanf("%d",&a);
    scanf("%d",&b);

    sum = a+b;
    sub = a-b;
    pro = a*b;

    if(sum > sub){
      if(sum > pro){
        printf("%d",sum);
      }
      else{
        printf("%d",pro);
      }
    }else{
      if(sub>pro){
        printf("%d",sub);
      }else{
        printf("%d",pro)
      }
    }

    return 0;
  }

Compiler output:
main.c: In function 'main':
main.c:22:25: error: expected ';' before '}' token
   22 |         printf("%d",pro)
      |                         ^
      |                         ;
   23 |       }
      |       ~
Language: Java

import java.util.*;
	class Main{
      public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        int k = sc.nextInt();
        int x = sc.nextInt();
        int n = 1+x-k;
        int j = 2k-1;
        for(int i = 0;i < j; i++){
          System.out.println(n+i);
        }
      }
    }


Compiler output:
Main.java:8: error: ';' expected
        int j = 2k-1;
                 ^
Main.java:8: error: not a statement
        int j = 2k-1;
                  ^
2 errors
Language: C++

#include <stdio.h>

int main(){
  int A,B,add,sub,mul;
  cin >> A,B;
  add = A + B;
  sub = A - B;
  mul = A * b;
  if(add > sub && add > mul){
    cout << add;
  }
  else if(sub > mul){
    cout << sub;
  }
  else
    cout << mul;
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:3: error: 'cin' was not declared in this scope
    5 |   cin >> A,B;
      |   ^~~
a.cc:8:13: error: 'b' was not declared in this scope
    8 |   mul = A * b;
      |             ^
a.cc:10:5: error: 'cout' was not declared in this scope
   10 |     cout << add;
      |     ^~~~
a.cc:13:5: error: 'cout' was not declared in this scope
   13 |     cout << sub;
      |     ^~~~
a.cc:16:5: error: 'cout' was not declared in this scope
   16 |     cout << mul;
      |     ^~~~
Language: Java

import java.util.Scanner;

public class Test {
	public static void main(String arg[]) {
		Scanner sc = new Scanner(System.in);
		
		int A = sc.nextInt();
		int B = sc.nextInt();
		
		if( (A+B) > (A-B) ) {
			if( (A+B) > (A*B) ) {
				System.out.print(A+B);
			} else if( (A+B) < (A*B) ) {
				System.out.print(A*B);
			}
		} else if ( (A+B) < (A-B) ) {
			if( (A-B) > (A*B) ) {
				System.out.print(A-B);
			} else if( (A-B) < (A*B) ) {
				System.out.print(A*B);
			}
		}
	}

}


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


import java.util.Scanner;

public class Test {
	public static void main(String arg[]) {
		Scanner sc = new Scanner(System.in);
		
		int A = sc.nextInt();
		int B = sc.nextInt();
		
		if( (A+B) > (A-B) ) {
			if( (A+B) > (A*B) ) {
				System.out.print(A+B);
			} else if( (A+B) < (A*B) ) {
				System.out.print(A*B);
			}
		} else if ( (A+B) < (A-B) ) {
			if( (A-B) > (A*B) ) {
				System.out.print(A-B);
			} else if( (A-B) < (A*B) ) {
				System.out.print(A*B);
			}
		}
	}

}


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

#include <stdio.h>

int max3 (int a, int b, int c)
{
  int max = a;
  
  if (b > max ) max = b;
  if (c > max) max = c;
  return max;
}

int main (void)
{
  int a, b, c;
  scanf("%d",&a);
  scanf("%d",&b);
  printf"%d",max3(a-b,a+b,a*b)
    return 0;
}
  

Compiler output:
a.cc: In function 'int main()':
a.cc:17:9: error: expected ';' before string constant
   17 |   printf"%d",max3(a-b,a+b,a*b)
      |         ^~~~
      |         ;
Language: C++

#include <stdio.h>

int max3 (int a, int b, int c)
{
  int max = a;
  
  if (b > max ) max = b;
  if (c > max) max = c;
  return max;
}

int main (void)
{
  scanf("%d",&a);
  scanf("%d",&b);
  printf"%d",max3(a-b,a+b,a*b)
    return 0;
}
  

Compiler output:
a.cc: In function 'int main()':
a.cc:14:15: error: 'a' was not declared in this scope
   14 |   scanf("%d",&a);
      |               ^
a.cc:15:15: error: 'b' was not declared in this scope
   15 |   scanf("%d",&b);
      |               ^
a.cc:16:9: error: expected ';' before string constant
   16 |   printf"%d",max3(a-b,a+b,a*b)
      |         ^~~~
      |         ;