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

#include<iostream>
#define int long long
const int p=1e9+7;
int f[55][55][55],c[55][55];
signed main(){
	int n;	
	std::cin>>n;
	f[1][1][1]=1;
	for(int i=0;i<=n;++i){
		c[i][0]=c[i][i]=1;
		for(int j=1;j<i;++j)c[i][j]=(c[i-1][j]+c[i-1][j-1])%p;
	}
	for(int i=1;i<n;++i){
		for(int j=1;j<=i;++j){
			for(int k=0;k<=j;++k){
				for(int l=0;l<=j;++l){
					for(int w=max(k-l,0LL);w+l-k+w+i<=n;++w){
						if(w+l-k+w>0){
							(f[w+l-k+w+i][w+l-k+w][w]+=f[i][j][k]*c[j][l]%p*c[w+l-k+w+i][i])%=p;
						}
					}
				}
			}
		}		
	}
	int ans=0;
	for(int i=1;i<=n;++i){
		for(int j=0;j<=i;++j)
			ans=(ans+f[n][i][j]*c[i][j])%p;
	}
	std::cout<<ans;
	return 0;
}



Compiler output:
a.cc: In function 'int main()':
a.cc:17:51: error: 'max' was not declared in this scope; did you mean 'std::max'?
   17 |                                         for(int w=max(k-l,0LL);w+l-k+w+i<=n;++w){
      |                                                   ^~~
      |                                                   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,
                 from a.cc:1:
/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 <iostream>
#include <algorithm>
#include <cmath>
#include <string>
using namespace std;
int main() {
	int a, b, c, d;
	cin >> a >> b >> c >> d;
	if (a >= b)
		int x = b;
	else
		int x = a;
	if (c >= d)
		int y = d;
	else
		int y = c;
	cout << x + y << "\n";
}

Compiler output:
a.cc: In function 'int main()':
a.cc:17:17: error: 'x' was not declared in this scope
   17 |         cout << x + y << "\n";
      |                 ^
a.cc:17:21: error: 'y' was not declared in this scope
   17 |         cout << x + y << "\n";
      |                     ^
Language: C++

#inclue<iostream>
using namespace std;
int main()
{
  int a,b,c,d;
  cin>>a;
  cin>>b;
  cin>>c;
  cin>>d;
  if(a<=b){
    if(c<=d){
      cout<<a+c;
    }
    else{
      cout<<a+d;
    }
  }
  else{
    if(c<=d){
      cout<<b+c;
    }
    else{
      cout<<b+d;
    }
  }
}

Compiler output:
a.cc:1:2: error: invalid preprocessing directive #inclue; did you mean #include?
    1 | #inclue<iostream>
      |  ^~~~~~
      |  include
a.cc: In function 'int main()':
a.cc:6:3: error: 'cin' was not declared in this scope
    6 |   cin>>a;
      |   ^~~
a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
  +++ |+#include <iostream>
    1 | #inclue<iostream>
a.cc:12:7: error: 'cout' was not declared in this scope
   12 |       cout<<a+c;
      |       ^~~~
a.cc:12:7: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:15:7: error: 'cout' was not declared in this scope
   15 |       cout<<a+d;
      |       ^~~~
a.cc:15:7: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:20:7: error: 'cout' was not declared in this scope
   20 |       cout<<b+c;
      |       ^~~~
a.cc:20:7: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:23:7: error: 'cout' was not declared in this scope
   23 |       cout<<b+d;
      |       ^~~~
a.cc:23:7: 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, C, D;
    cin >> A >> B >> C >> D;

    int bus_min = min(A,B);
    int train_min= min(C,D)

    cout << bus_min + train_min << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:5: error: expected ',' or ';' before 'cout'
   11 |     cout << bus_min + train_min << endl;
      |     ^~~~
Language: C++

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

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

    int min = 0;

    min += min(A,B) + min(C,D);

    cout << min << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:15: error: 'min' cannot be used as a function
   10 |     min += min(A,B) + min(C,D);
      |            ~~~^~~~~
a.cc:10:26: error: 'min' cannot be used as a function
   10 |     min += min(A,B) + min(C,D);
      |                       ~~~^~~~~
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
int main() {
  int A,B,C,D,E,F;
  cin >> A >> B >> C >> D;
  if(A > B){
  E=B
  }
  else{
  E=A
  }
  if(C>D){
  F=D
  }
  else{
  F=C
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:6: error: expected ';' before '}' token
    8 |   E=B
      |      ^
      |      ;
    9 |   }
      |   ~   
a.cc:11:6: error: expected ';' before '}' token
   11 |   E=A
      |      ^
      |      ;
   12 |   }
      |   ~   
a.cc:14:6: error: expected ';' before '}' token
   14 |   F=D
      |      ^
      |      ;
   15 |   }
      |   ~   
a.cc:17:6: error: expected ';' before '}' token
   17 |   F=C
      |      ^
      |      ;
   18 |   }
      |   ~
Language: C++

#include <iostream>
#include <string>
#include<minmax.h>
using namespace std;
int main(void)
{
	int a, b, c, d;
	cin >> a >> b >> c >> d;

	cout << min(a, b) + min(c, d);

}

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

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

int main() {
  int A, B, C, D;
  cin >> A >> B >> C >> D;
  cout << min(A, B)+min(C+D) << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:24: error: no matching function for call to 'min(int)'
    8 |   cout << min(A, B)+min(C+D) << 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:233:5: note: candidate: 'template<class _Tp> constexpr const _Tp& std::min(const _Tp&, const _Tp&)'
  233 |     min(const _Tp& __a, const _Tp& __b)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:233:5: note:   candidate expects 2 arguments, 1 provided
/usr/include/c++/14/bits/stl_algobase.h:281:5: note: candidate: 'template<class _Tp, class _Compare> constexpr const _Tp& std::min(const _Tp&, const _Tp&, _Compare)'
  281 |     min(const _Tp& __a, const _Tp& __b, _Compare __comp)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:281: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:5686:5: note: candidate: 'template<class _Tp> constexpr _Tp std::min(initializer_list<_Tp>)'
 5686 |     min(initializer_list<_Tp> __l)
      |     ^~~
/usr/include/c++/14/bits/stl_algo.h:5686:5: note:   template argument deduction/substitution failed:
a.cc:8:24: note:   mismatched types 'std::initializer_list<_Tp>' and 'int'
    8 |   cout << min(A, B)+min(C+D) << endl;
      |                     ~~~^~~~~
/usr/include/c++/14/bits/stl_algo.h:5696:5: note: candidate: 'template<class _Tp, class _Compare> constexpr _Tp std::min(initializer_list<_Tp>, _Compare)'
 5696 |     min(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
/usr/include/c++/14/bits/stl_algo.h:5696:5: note:   candidate expects 2 arguments, 1 provided
Language: C++

#include <iostream>
#include <algorithm>
#include <vector>
#include <queue>
#include <string>
#include <cstring>
#include <utility>
#include <set>
#include <stack>
#include <climits>
#include <cmath>
#include <iomanip>
#include <unordered_map>
#include <map>
#include <boost/multiprecision/cpp_int.hpp>

#define rep(i,n) for(int i=0, i##_len=(n); i<i##_len; ++i)
#define rep1(i,n) for(int i=1, i##_len=(n); i<=i##_len; ++i)
#define reps(i,s,n) for(int i=s, i##_len=(n); i<i##_len; ++i)
#define all(x) (x).begin(),(x).end()
#define MEMSET(v, h) memset((v), h, sizeof(v))
typedef long long ll;
typedef long double ld;
const char sp = ' ';

using namespace boost::multiprecision;
using namespace std;

int main(void){
    ll A, B, C, D;
    cin>A>>B>>C>>D;
    cout<<min(A, B)+min(C,D)<<endl;
    return 0;
}


Compiler output:
a.cc:15:10: fatal error: boost/multiprecision/cpp_int.hpp: No such file or directory
   15 | #include <boost/multiprecision/cpp_int.hpp>
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
Language: C++

#include<iostream>
using namespace std;
int main(){
  int a,b,c,d; cin >> a >> b >> c >> d;
  cout << min(a,b) + min(c,d);


Compiler output:
a.cc: In function 'int main()':
a.cc:5:31: error: expected '}' at end of input
    5 |   cout << min(a,b) + min(c,d);
      |                               ^
a.cc:3:11: note: to match this '{'
    3 | int main(){
      |           ^
Language: C

#include<stdio.h>
int main()
{
    int A,B,C,D,Bus,Train;
    scanf(%d %d %d %d ,&A,&B,&C,&D);
    if (A<B) { Bus = A}:
    else if (C<D) {Train = C};
    printf("%d ",A+C);
    return 0;
}



Compiler output:
main.c: In function 'main':
main.c:5:11: error: expected expression before '%' token
    5 |     scanf(%d %d %d %d ,&A,&B,&C,&D);
      |           ^
main.c:6:23: error: expected ';' before '}' token
    6 |     if (A<B) { Bus = A}:
      |                       ^
      |                       ;
main.c:6:24: error: expected expression before ':' token
    6 |     if (A<B) { Bus = A}:
      |                        ^
Language: C++

#include<iostream>

using namespace std;

int main(){
  int A, B, C, D;
  cin >> A >> B >> C >> D;
  
 if (A >= B && C >= D) {
   cout << B + D;
 }
 else if (A >= B && D >= C) {
   cout << B + C;
 }
  else if (B >= A && C >= D) {
   cout << A + D
 }
  else if (B >= A && D >= C) {
   cout << A+ C;
 }
}
  

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

#include <iostream>
#include <algorithm>
using namespace std;
int main()
{
  int A, B, C, D;
  cin A >> B >> C >> D;
  cout << min(A, B) + min(C, D) << endl;
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:6: error: expected ';' before 'A'
    7 |   cin A >> B >> C >> D;
      |      ^~
      |      ;
Language: Java

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


public class Solution {

  public static void main(String[] args) throws IOException {
    Scanner sc = new Scanner(System.in);
    int A = sc.nextInt(), B = sc.nextInt();
    int S = 0;
    if(A <= B){
      S += A; 
    }
    else{
      S += B;
    }
    int C = sc.nextInt(), D = sc.nextInt();
    if(C <= D){
      S += C; 
    }
    else{
      S += D;
    }
    System.out.println(S);
  }
}


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

import java.util.Scanner;

public class Atcodercontest {

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		 Scanner sc= new Scanner(System.in);
		 int A = sc.nextInt();
		 int B = sc.nextInt();
		 int C = sc.nextInt();
		 int D = sc.nextInt();
		 int Train = 0;
		 int Bus = 0;
		 if(A>B) {
			 Train = Train + B;
		 }
		 else {
			 Train = Train + A;
		 }
		 if(C>D) {
			 Bus = Bus + D;
		 }
		 else {
			 Bus = Bus + C;
		 }
		 System.out.println(Train+Bus);
	}

}


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

import java.util.Scanner;

public class abc092_a {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		System.out.println(Math.min(sc.nextInt(), sc.nextInt()) + Math.min(sc.nextInt(), sc.nextInt()));
	}

}


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

#include<stdio.h> 
int main() 
{ 
int a,b,c,d; 
scanf("%d%d%d%d",a,b,c,d);
if(a<b)x=a; 
else x=b; 
if(c<d)y=c; 
else y=d; 
printf("%d\n",x+y); 
return 0; 
}

Compiler output:
main.c: In function 'main':
main.c:6:8: error: 'x' undeclared (first use in this function)
    6 | if(a<b)x=a;
      |        ^
main.c:6:8: note: each undeclared identifier is reported only once for each function it appears in
main.c:8:8: error: 'y' undeclared (first use in this function)
    8 | if(c<d)y=c;
      |        ^
Language: C++

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

Compiler output:
a.cc:3:5: error: cannot declare '::main' to be a global variable
    3 | int main{
      |     ^~~~
a.cc:4:3: error: expected primary-expression before 'int'
    4 |   int a,b,c,d;
      |   ^~~
a.cc:4:3: error: expected '}' before 'int'
a.cc:3:9: note: to match this '{'
    3 | int main{
      |         ^
a.cc:5:3: error: 'cin' does not name a type
    5 |   cin>>a>>b>>c>>d;
      |   ^~~
a.cc:6:3: error: 'cout' does not name a type
    6 |   cout<<min(a,b)+min(c,d)<<endl;
      |   ^~~~
a.cc:7:3: error: expected unqualified-id before 'return'
    7 |   return 0;
      |   ^~~~~~
a.cc:8:1: error: expected declaration before '}' token
    8 | }
      | ^
Language: C++

#include<bits/stdc++.h>
#define yes cout<<"Yes"<<endl;
#define no cout<<"No"<<endl;
#define ll long long int
#define tc while(tc--)
using namespace std;
int main()
{
    ll tc,a,b,c,d,n,x,y,z,cnt=0,sum=0,tot=0;
    string s,s1,s2;
    cin>>a>>b>>c>>d;
    cout<<min(a,b)+min(c,d)<<endl;


}



Compiler output:
a.cc: In function 'int main()':
a.cc:5:12: error: expected unqualified-id before 'while'
    5 | #define tc while(tc--)
      |            ^~~~~
a.cc:9:8: note: in expansion of macro 'tc'
    9 |     ll tc,a,b,c,d,n,x,y,z,cnt=0,sum=0,tot=0;
      |        ^~
a.cc:11:10: error: 'a' was not declared in this scope
   11 |     cin>>a>>b>>c>>d;
      |          ^
a.cc:11:13: error: 'b' was not declared in this scope
   11 |     cin>>a>>b>>c>>d;
      |             ^
a.cc:11:16: error: 'c' was not declared in this scope
   11 |     cin>>a>>b>>c>>d;
      |                ^
a.cc:11:19: error: 'd' was not declared in this scope
   11 |     cin>>a>>b>>c>>d;
      |                   ^
Language: C++

#include <iostream>

using namespace std;

int main()
{
    int a , b , c , d;
    cin >> a >> b >> c >> d;
    int bus = min(a , b);
    int train = min (c , d);
    cout << bus + train;
    }
    return 0;
}


Compiler output:
a.cc:13:5: error: expected unqualified-id before 'return'
   13 |     return 0;
      |     ^~~~~~
a.cc:14:1: error: expected declaration before '}' token
   14 | }
      | ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b, c, d;
  cin>>a>>b>>c>>d;
  if(a<=b) {
    int &e = a;
  }
  else {
    int &e = b;
  }
  if(c<=d) {
    int &f = c;
  }
  else {
    int &f = d;
  }
  cout << e+f << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:18:11: error: 'e' was not declared in this scope
   18 |   cout << e+f << endl;
      |           ^
a.cc:18:13: error: 'f' was not declared in this scope
   18 |   cout << e+f << endl;
      |             ^
Language: C++

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

int main(){
  
  int a,b,c,d;
  cin >> a >> b >> c >> d;
  
    cout << min(a,b) + min(c,d)<< endl;
  
  }
  
  


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

A = [int(input()) for i in range(4)]
ans=0
if A[0]<A[1]:
    ans+=A[0]
else:
    ans= ans+A[1]
if A[2]<A[3]:
    ans+=A[2]
else:
    ans+=A[3]
print(ans)

Compiler output:
a.cc:1:1: error: 'A' does not name a type
    1 | A = [int(input()) for i in range(4)]
      | ^
Language: C

#include <stdio.h>

int main() {
  int A;
  int B;
  int C;
  int D;
  

  scanf("%d %d %d %d", &A, &B, &C, &D);
  if(A<B) {
	  if(C < D) {
       printf("%d",A+C);
	  }
	  else {
	   printf("%d",A+D);
	  }  
  } 
  else {
	  if(C < D) {
       printf("%d",B+C);
	  }
	  else {
	   printf("%d",B+D);
	  }
  }

  return 0;

Compiler output:
main.c: In function 'main':
main.c:28:3: error: expected declaration or statement at end of input
   28 |   return 0;
      |   ^~~~~~
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,C,D;
    cin >>A >>B>>C>>D;
    cout << min(A,b)+min(C,D) << endl;



}


Compiler output:
a.cc: In function 'int main()':
a.cc:17:19: error: 'b' was not declared in this scope
   17 |     cout << min(A,b)+min(C,D) << endl;
      |                   ^
Language: C++

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

int main(){
  int a,b,c,d;
  cin>>a>>b>>c>>d;
  if(a+d>c+b){
    cout<<c+b<<endl;
  }
  else if{
    cout<<a+d<<endl;
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:10: error: expected '(' before '{' token
   10 |   else if{
      |          ^
      |          (
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main(){
  int A,B,C,D;
  cin>>A>>B>>C>>D;
  cout<<min(A,B)+min(C+D)<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:21: error: no matching function for call to 'min(int)'
    6 |   cout<<min(A,B)+min(C+D)<<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:233:5: note: candidate: 'template<class _Tp> constexpr const _Tp& std::min(const _Tp&, const _Tp&)'
  233 |     min(const _Tp& __a, const _Tp& __b)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:233:5: note:   candidate expects 2 arguments, 1 provided
/usr/include/c++/14/bits/stl_algobase.h:281:5: note: candidate: 'template<class _Tp, class _Compare> constexpr const _Tp& std::min(const _Tp&, const _Tp&, _Compare)'
  281 |     min(const _Tp& __a, const _Tp& __b, _Compare __comp)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:281: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:5686:5: note: candidate: 'template<class _Tp> constexpr _Tp std::min(initializer_list<_Tp>)'
 5686 |     min(initializer_list<_Tp> __l)
      |     ^~~
/usr/include/c++/14/bits/stl_algo.h:5686:5: note:   template argument deduction/substitution failed:
a.cc:6:21: note:   mismatched types 'std::initializer_list<_Tp>' and 'int'
    6 |   cout<<min(A,B)+min(C+D)<<endl;
      |                  ~~~^~~~~
/usr/include/c++/14/bits/stl_algo.h:5696:5: note: candidate: 'template<class _Tp, class _Compare> constexpr _Tp std::min(initializer_list<_Tp>, _Compare)'
 5696 |     min(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
/usr/include/c++/14/bits/stl_algo.h:5696:5: note:   candidate expects 2 arguments, 1 provided
Language: C++

#include <bits/stdc++.h>
using namespace std;
using ll = long long; // ll は long long　と同じとする。(int64_t)
int main(){
    int A , B  C , D;
    cin >> A >> B >> C >> D;
    cout << min(A , B) + min(C , D) << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:16: error: expected initializer before 'C'
    5 |     int A , B  C , D;
      |                ^
a.cc:6:17: error: 'B' was not declared in this scope
    6 |     cin >> A >> B >> C >> D;
      |                 ^
a.cc:6:22: error: 'C' was not declared in this scope
    6 |     cin >> A >> B >> C >> D;
      |                      ^
a.cc:6:27: error: 'D' was not declared in this scope
    6 |     cin >> A >> B >> C >> D;
      |                           ^
Language: C++

package main

import (
	"bufio"
	"fmt"
	"os"
	"strconv"
)

func out(x ...interface{}) {
	fmt.Println(x...)
}

var sc = bufio.NewScanner(os.Stdin)

func getInt() int {
	sc.Scan()
	i, e := strconv.Atoi(sc.Text())
	if e != nil {
		panic(e)
	}
	return i
}

func getString() string {
	sc.Scan()
	return sc.Text()
}

// min, max, asub, absなど基本関数
func max(a, b int) int {
	if a > b {
		return a
	}
	return b
}

func min(a, b int) int {
	if a < b {
		return a
	}
	return b
}

func asub(a, b int) int {
	if a > b {
		return a - b
	}
	return b - a
}

func abs(a int) int {
	if a >= 0 {
		return a
	}
	return -a
}

func main() {
	sc.Split(bufio.ScanWords)

	A, B, C, D := getInt(), getInt(), getInt(), getInt()

	out(min(A, B) + min(C, D))
}


Compiler output:
a.cc:1:1: error: 'package' does not name a type
    1 | package main
      | ^~~~~~~
a.cc:10:26: error: expected unqualified-id before ')' token
   10 | func out(x ...interface{}) {
      |                          ^
a.cc:14:1: error: 'var' does not name a type
   14 | var sc = bufio.NewScanner(os.Stdin)
      | ^~~
a.cc:25:1: error: 'func' does not name a type
   25 | func getString() string {
      | ^~~~
a.cc:31:1: error: 'func' does not name a type
   31 | func max(a, b int) int {
      | ^~~~
a.cc:38:1: error: 'func' does not name a type
   38 | func min(a, b int) int {
      | ^~~~
a.cc:45:1: error: 'func' does not name a type
   45 | func asub(a, b int) int {
      | ^~~~
a.cc:52:1: error: 'func' does not name a type
   52 | func abs(a int) int {
      | ^~~~
a.cc:59:1: error: 'func' does not name a type
   59 | func main() {
      | ^~~~
Language: C++

#include<iostream>
using namespace std;

int min(int a,int b){
  return (a>=b) b : a ;
}

int main() {
  
    int a,b,c,d ;
    cin >> a >> b >> c >> d ;
    
    cout << min(a,b)+min(c,d) << endl ;
	return 0;
}



Compiler output:
a.cc: In function 'int min(int, int)':
a.cc:5:16: error: expected ';' before 'b'
    5 |   return (a>=b) b : a ;
      |                ^~
      |                ;
Language: C++

#include<iostream>
using namespace std;

int min(int a,int b){
  return (a>=B) b : a ;
}

int main() {
  
    int a,b,c,d ;
    cin >> a >> b >> c >> d ;
    
    cout << min(a,b)+min(c,d) << endl ;
	return 0;
}



Compiler output:
a.cc: In function 'int min(int, int)':
a.cc:5:14: error: 'B' was not declared in this scope
    5 |   return (a>=B) b : a ;
      |              ^
a.cc:5:16: error: expected ';' before 'b'
    5 |   return (a>=B) b : a ;
      |                ^~
      |                ;
Language: C++

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

int main() {
  int a,b,c,d;
  cin>>a>>b>>c>>d;
  cout<<min(a,b)+min(c+d)<<endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:21: error: no matching function for call to 'min(int)'
    7 |   cout<<min(a,b)+min(c+d)<<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:233:5: note: candidate: 'template<class _Tp> constexpr const _Tp& std::min(const _Tp&, const _Tp&)'
  233 |     min(const _Tp& __a, const _Tp& __b)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:233:5: note:   candidate expects 2 arguments, 1 provided
/usr/include/c++/14/bits/stl_algobase.h:281:5: note: candidate: 'template<class _Tp, class _Compare> constexpr const _Tp& std::min(const _Tp&, const _Tp&, _Compare)'
  281 |     min(const _Tp& __a, const _Tp& __b, _Compare __comp)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:281: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:5686:5: note: candidate: 'template<class _Tp> constexpr _Tp std::min(initializer_list<_Tp>)'
 5686 |     min(initializer_list<_Tp> __l)
      |     ^~~
/usr/include/c++/14/bits/stl_algo.h:5686:5: note:   template argument deduction/substitution failed:
a.cc:7:21: note:   mismatched types 'std::initializer_list<_Tp>' and 'int'
    7 |   cout<<min(a,b)+min(c+d)<<endl;
      |                  ~~~^~~~~
/usr/include/c++/14/bits/stl_algo.h:5696:5: note: candidate: 'template<class _Tp, class _Compare> constexpr _Tp std::min(initializer_list<_Tp>, _Compare)'
 5696 |     min(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
/usr/include/c++/14/bits/stl_algo.h:5696:5: note:   candidate expects 2 arguments, 1 provided
Language: C++

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

int main(){
    int a,,b,c,d;
    cin >> a >> b >> c >> d;
    cout << min(a,b) + min(c,d) << endl;
}

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

// 失敗するからこそ そこから立ち向かって行く強さがあってそんな強さが本当の強さだと私は思うから
// ぜったいあきらめない
#if defined(DAIJOBU)
#include "/home/ichigo/includes.hpp"
#include "/home/ichigo/debug.hpp"
#define deb(x...) cerr << "[" << #x << "] = ["; _print(x)
#else
#include <bits/stdc++.h>
#define deb(x...)
#endif
#define mp make_pair
#define mt make_tuple
#define fi first
#define se second
#define pb push_back
#define all(x) (x).begin(), (x).end()
#define rall(x) (x).rbegin(), (x).rend()
#define forn(i, n) for (int i = 0; i < (int)(n); ++i)
#define for1(i, n) for (int i = 1; i <= (int)(n); ++i)
#define ford(i, n) for (int i = (int)(n) - 1; i >= 0; --i)
#define fore(i, a, b) for (int i = (int)(a); i <= (int)(b); ++i)

using namespace std;
mt19937 rng(chrono::steady_clock::now().time_since_epoch().count());

typedef pair<int, int> pii;
typedef vector<int> vi;
typedef vector<pii> vpi;
typedef vector<vi> vvi;
typedef long long lint;
typedef vector<lint> vlint;
typedef vector<vlint> vvlint;
typedef pair<lint, lint> plint;
typedef double ld;

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

int h(int x, int y){
	return x * x + 2 * x * y + x + 1;
}

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

	int a[4];
	forn(i, n)cin >> a[i];
	sort(a,a  + 4);
	cout << a[0] + a[1] << '\n';
	return 0;
}



Compiler output:
a.cc: In function 'int main()':
a.cc:48:17: error: 'n' was not declared in this scope
   48 |         forn(i, n)cin >> a[i];
      |                 ^
a.cc:18:46: note: in definition of macro 'forn'
   18 | #define forn(i, n) for (int i = 0; i < (int)(n); ++i)
      |                                              ^
Language: C++

#include <iostream>
using namespace std;
int main(){
  int a,b,count=0;
  for(i=0;i<2;i++){
    cin >> a >> b;
    count += min(a,b);
  }
  cout << count;
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:7: error: 'i' was not declared in this scope
    5 |   for(i=0;i<2;i++){
      |       ^
Language: C++

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

int main(){
int a,b,c,d;
cin>>a>>b>>c>>d;
cout<<min(a,b)+min(c,d)<<Endl;

}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:26: error: 'Endl' was not declared in this scope
    9 | cout<<min(a,b)+min(c,d)<<Endl;
      |                          ^~~~
Language: C++

#include<biits/stdc++.h>
using namespace std;
int main(){
  int a,b,c,d;
  cin >> a >> b >> c >> d;
  cout << min(a,b)+min(c,d) << endl;
}

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

import ava.util.Scanner;
public class Main{
  public static void main(String[]args){
    Scanner scan = new Scanner(System.in);
    int a,b,c,d;
    a=scan.nextInt();
    b=scan.nextInt();
    c=scan.nextInt();
    d=scan.nextInt();
    int tmp=Math.min(a,b)+Math.min(c,d);
    System.out.println(tmp);
  }
}

    

Compiler output:
Main.java:1: error: package ava.util does not exist
import ava.util.Scanner;
               ^
Main.java:4: error: cannot find symbol
    Scanner scan = new Scanner(System.in);
    ^
  symbol:   class Scanner
  location: class Main
Main.java:4: error: cannot find symbol
    Scanner scan = new Scanner(System.in);
                       ^
  symbol:   class Scanner
  location: class Main
3 errors
Language: C++

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

//////全探索したいときに開けよ////////
vector<vector<int>> fspattern;
vector<int> fspattern_draft;
int fspcnt = 0;

void setfspattern_core(int floor,int number,int degree){
  if(floor==degree){
    fspattern.at(fspcnt) = fspattern_draft;
    fspcnt++;
  }else{
    rep(i,number){
      fspattern_draft.at(floor) = i;
      setfspattern_core(floor+1,number,degree);
    }
  }
}

void setfspattern(int number,int degree){
  fspcnt = 0;
  int64_t array_num = 1;
  rep(i,degree){
    array_num *= number;
  }
  fspattern = vector<vector<int>>(array_num,vector<int>(degree));
  fspattern_draft = vector<int>(degree);
  setfspattern_core(0,number,degree);
}

//////nCrのmodを求めたいときに開けよ/////////
//int64_t univMod = 1000000007;
//int64_t factnum = 100000
//vector<int64_t> modfact(factnum);
//vector<int64_t> modinvfact(factnum);

/*void setmodfact(){
  for(int i=0;i<factnum;i++){
    if(i == 0){
      modfact.at(i) = 1;
    }else{
      modfact.at(i) = (modfact.at(i-1)*i)%univMod;
    }
  }
}

int64_t calcmodpower(int64_t a,int64_t n){
  int64_t res = 1;
  while(n != 0){
    if(n & 1){
      res = (res * a) % univMod;
    }
    a = (a*a) % univMod;
    n = n >> 1;
  }
  return res;
}

int64_t calcinverse(int64_t n){
	return calcmodpower(n,univMod-2);
}

void setmodinvfact(){
  for(int i=0;i<factnum;i++){
    if(i==0){
      modinvfact.at(i) = 1;
    }else{
      modinvfact.at(i) = calcmodpower(modfact.at(i),univMod-2);
    }
  }
}*/


/*
int64_t calcGCD(int64_t a,int64_t b){
	int64_t p = a;
	int64_t q = b;
	int64_t c = a%b;
	while(c != 0){
		p = q;
		q = c;
		c = p%q;
	}
	return q;
}
*/
struct position{
  int x;
  int y;
};

int main(){
  int a,b,c,d;
  cin >> a >> b >> c >> d;
  cout << min(a,b)+min(c,d) << endl;

  }
          
             
          
        
        
        
          
}

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

#include<stdio.h>
#include<algorithm>
#include<math.h>
int main(){
    int a, b, c, d;
    scanf("%d%d%d%d",&a,&b,&c,&d);
    printf("%d",min(a,b)+min(c,d));
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:17: error: 'min' was not declared in this scope; did you mean 'std::min'?
    7 |     printf("%d",min(a,b)+min(c,d));
      |                 ^~~
      |                 std::min
In file included from /usr/include/c++/14/algorithm:61,
                 from a.cc:2:
/usr/include/c++/14/bits/stl_algo.h:5696:5: note: 'std::min' declared here
 5696 |     min(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
Language: C++

#include<stdio.h>
#include<algorithm>
int main(){
    int a, b, c, d;
    scanf("%d%d%d%d",&a,&b,&c,&d);
    printf("%d",min(a,b)+min(c,d));
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:17: error: 'min' was not declared in this scope; did you mean 'std::min'?
    6 |     printf("%d",min(a,b)+min(c,d));
      |                 ^~~
      |                 std::min
In file included from /usr/include/c++/14/algorithm:61,
                 from a.cc:2:
/usr/include/c++/14/bits/stl_algo.h:5696:5: note: 'std::min' declared here
 5696 |     min(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
Language: C++

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

int main() {
  int a,b,c,d;
  cin >> a >> b >> c >>d;
  cout << min(a,b)+min(c+d);
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:23: error: no matching function for call to 'min(int)'
    7 |   cout << min(a,b)+min(c+d);
      |                    ~~~^~~~~
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:233:5: note: candidate: 'template<class _Tp> constexpr const _Tp& std::min(const _Tp&, const _Tp&)'
  233 |     min(const _Tp& __a, const _Tp& __b)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:233:5: note:   candidate expects 2 arguments, 1 provided
/usr/include/c++/14/bits/stl_algobase.h:281:5: note: candidate: 'template<class _Tp, class _Compare> constexpr const _Tp& std::min(const _Tp&, const _Tp&, _Compare)'
  281 |     min(const _Tp& __a, const _Tp& __b, _Compare __comp)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:281: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:5686:5: note: candidate: 'template<class _Tp> constexpr _Tp std::min(initializer_list<_Tp>)'
 5686 |     min(initializer_list<_Tp> __l)
      |     ^~~
/usr/include/c++/14/bits/stl_algo.h:5686:5: note:   template argument deduction/substitution failed:
a.cc:7:23: note:   mismatched types 'std::initializer_list<_Tp>' and 'int'
    7 |   cout << min(a,b)+min(c+d);
      |                    ~~~^~~~~
/usr/include/c++/14/bits/stl_algo.h:5696:5: note: candidate: 'template<class _Tp, class _Compare> constexpr _Tp std::min(initializer_list<_Tp>, _Compare)'
 5696 |     min(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
/usr/include/c++/14/bits/stl_algo.h:5696:5: note:   candidate expects 2 arguments, 1 provided
Language: C++

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

int main(void)
{
  int a,b,c,d; cin>>a>>b>>c>>d;
  int ans = min(a,b)+min(c,d);
  cout<<and<<endl;

  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:9:12: error: expected identifier before '<<' token
    9 |   cout<<and<<endl;
      |            ^~
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main (){
int a,b,c,d;
  cin>>a>>b>>c>>d;
  int co=0;
  co+=min(a,b)+min(c+d);
  cout<<co;
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:19: error: no matching function for call to 'min(int)'
    7 |   co+=min(a,b)+min(c+d);
      |                ~~~^~~~~
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:233:5: note: candidate: 'template<class _Tp> constexpr const _Tp& std::min(const _Tp&, const _Tp&)'
  233 |     min(const _Tp& __a, const _Tp& __b)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:233:5: note:   candidate expects 2 arguments, 1 provided
/usr/include/c++/14/bits/stl_algobase.h:281:5: note: candidate: 'template<class _Tp, class _Compare> constexpr const _Tp& std::min(const _Tp&, const _Tp&, _Compare)'
  281 |     min(const _Tp& __a, const _Tp& __b, _Compare __comp)
      |     ^~~
/usr/include/c++/14/bits/stl_algobase.h:281: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:5686:5: note: candidate: 'template<class _Tp> constexpr _Tp std::min(initializer_list<_Tp>)'
 5686 |     min(initializer_list<_Tp> __l)
      |     ^~~
/usr/include/c++/14/bits/stl_algo.h:5686:5: note:   template argument deduction/substitution failed:
a.cc:7:19: note:   mismatched types 'std::initializer_list<_Tp>' and 'int'
    7 |   co+=min(a,b)+min(c+d);
      |                ~~~^~~~~
/usr/include/c++/14/bits/stl_algo.h:5696:5: note: candidate: 'template<class _Tp, class _Compare> constexpr _Tp std::min(initializer_list<_Tp>, _Compare)'
 5696 |     min(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
/usr/include/c++/14/bits/stl_algo.h:5696:5: note:   candidate expects 2 arguments, 1 provided
Language: C++

#include<iostream>
using namespace std;
int main(){
  	int a,b,c,d，x,y;
  	cin >> a >> b >> c >> d;
  	x=a;
  	if(a>b)
      	x=b;
  	if(c<d)
      	x+=c;
  	else
      	x+=d;
  	cout << x << endl;
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:31: error: 'd' was not declared in this scope
    5 |         cin >> a >> b >> c >> d;
      |                               ^
a.cc:6:9: error: 'x' was not declared in this scope
    6 |         x=a;
      |         ^
Language: C++

#include<iostream>
using namespace std;
int main()
{
{  int w,x,y,z,h,g;
   cin>>w>>x>>y>>z;
   h=min(w,x);
   g=min(y,z);
   
   cout<<h+g;


   
   
   return 0;
}



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

#include<iostream>
using namespace std;
int main()
{
{  int w,x,y,z,h,g,k;
   cin>>w>>x>>y>>z;
   h=min(w,x);
   g=min(y,z);
   k=h+g;
   cout<<k;


   return 0;
}



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

#include <iostream>

using namespace std;

int main()
{
    int A,B,C,D,S;
    cin>>A>>B>>C>>D;

    if(A>=B)
    {
        S=B;
    }
    else{S=A}

    if(C>=D)
    {
        S=S+D;
    }
    else{S=S+C}
    
    cout<<S;

    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:14:13: error: expected ';' before '}' token
   14 |     else{S=A}
      |             ^
      |             ;
a.cc:20:15: error: expected ';' before '}' token
   20 |     else{S=S+C}
      |               ^
      |               ;
Language: C++

#include<bits/stdc++.h>

#define rep(i,n) for(int i = 0; i < (n); i++)
#define ll long long

using namespace std;

int main(){
  valarray<int>ab, cd;
  cin>>ab[0];
  cin>>ab[1];
  cin>>cd[0];
  cin>>cd[1];

  cout<<min(ab.begin(), ab.end())+min(cd.begin(), cd.end());
  
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:15:16: error: 'class std::valarray<int>' has no member named 'begin'
   15 |   cout<<min(ab.begin(), ab.end())+min(cd.begin(), cd.end());
      |                ^~~~~
a.cc:15:28: error: 'class std::valarray<int>' has no member named 'end'
   15 |   cout<<min(ab.begin(), ab.end())+min(cd.begin(), cd.end());
      |                            ^~~
a.cc:15:42: error: 'class std::valarray<int>' has no member named 'begin'
   15 |   cout<<min(ab.begin(), ab.end())+min(cd.begin(), cd.end());
      |                                          ^~~~~
a.cc:15:54: error: 'class std::valarray<int>' has no member named 'end'
   15 |   cout<<min(ab.begin(), ab.end())+min(cd.begin(), cd.end());
      |                                                      ^~~
Language: C++

        #include <bits/stdc++.h>
        using namespace std;
         
        int main(){
          //int a,b,c;
          string a, b, c, d;
          cin >> a >> b >> c >>d;
          //cin >> s;
          //if((a+b)%2==1)cout << 1 + (a+b)/2 << endl;
          //else cout << (a+b)/2 << endl;
          int x, y;
          x = min(a,b);
          y = min(c,d);
          cout << x+y << endl;
          return 0;
        }

Compiler output:
a.cc: In function 'int main()':
a.cc:12:18: error: cannot convert 'const std::__cxx11::basic_string<char>' to 'int' in assignment
   12 |           x = min(a,b);
      |               ~~~^~~~~
      |                  |
      |                  const std::__cxx11::basic_string<char>
a.cc:13:18: error: cannot convert 'const std::__cxx11::basic_string<char>' to 'int' in assignment
   13 |           y = min(c,d);
      |               ~~~^~~~~
      |                  |
      |                  const std::__cxx11::basic_string<char>
Language: C++

#include <iostream>
int main(){int a,b,c,d;std::cin>>a>>b>>c>>d;std::cout<<min({a, b}) + min({c, d});}

Compiler output:
a.cc: In function 'int main()':
a.cc:2:56: error: 'min' was not declared in this scope; did you mean 'std::min'?
    2 | int main(){int a,b,c,d;std::cin>>a>>b>>c>>d;std::cout<<min({a, b}) + min({c, d});}
      |                                                        ^~~
      |                                                        std::min
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:281:5: note: 'std::min' declared here
  281 |     min(const _Tp& __a, const _Tp& __b, _Compare __comp)
      |     ^~~
Language: C++

#include <iostream>

using namespace std;

int main()
{
    int a,b,c,d,x,v,n;
    cin>>a>>b>>c>>d;
    x=a+c;
    v=a+d;
    n=b+c;
    m=b+d;
    if(x<v&&x<n&&x<m)
    cout <<x<<' ';
    else if(v<n&&v<m&&v<x)
    cout <<v<<' ';
    else if(n<m&&n<v&&n<x)
    cout <<n<<' ';
    else if(m<n&&m<v&&m<x)
    cout <<m<<' ';
    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:12:5: error: 'm' was not declared in this scope
   12 |     m=b+d;
      |     ^
Language: C++

#include <iostream>

using namespace std;

int main()
{
    int a,b,c,d,z,x,v,n;
    cin>>a>>b>>c>>d;
    x=a+c;
    v=a+d;
    n=b+c;
    m=b+d;
    if(x<v&&x<n&&x<m)
    cout <<x<<' ';
    else if(v<n&&v<m&&v<x)
    cout <<v<<' '; 
    else if(n<m&&n<v&&n<x)
    cout <<n<<' '; 
    else if(m<n&&m<v&&m<x)
    cout <<m<<' '; 
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:5: error: 'm' was not declared in this scope
   12 |     m=b+d;
      |     ^
Language: C++

#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <string.h>
#include <queue>
#include <algorithm>
using namespace std;
typedef unsigned int uint;
typedef long long ll;
typedef pair<int, int> P;
const int c_INF = 111111111;
const int c_mINF = -111111111;
const int c_YET = -1;
const int c_Dx[4] = { 0,0,1,-1 };
const int c_Dy[4] = { 1,-1,0,0 };
const int c_div = 1000000007; //10^9 + 7


int main() {
	int A, B, C, D;
	scanf("%d%d%d%d", &A, &B, &C, &D);

	printf("%d", , min(A, B) + min(C, D));


}

Compiler output:
a.cc: In function 'int main()':
a.cc:23:22: error: expected primary-expression before ',' token
   23 |         printf("%d", , min(A, B) + min(C, D));
      |                      ^
Language: Java

import java.util.Scanner;

class TravelingBudget {
  public static void main(String args[]) {
  int A;
  int B;
  int C;
  int D;
  int E =0;
  int F =0;
  Scanner sc = new Scanner(System.in);

  System.err.print("A ");
  A = sc.nextInt();

  System.err.print("B ");
  B = sc.nextInt();

  System.err.print("C ");
  C = sc.nextInt();

  System.err.print("D ");
  D = sc.nextInt();

          if( A < B ) {
              E = A;
          };
          if( A >= B ) {
              E =B;
          };
          if( C < D ) {
              F = C;
          }
          if( C >= D ) {
              F = D;
          }
          sum =(E + F);
          System.out.println(E + F);


}
                      }


Compiler output:
Main.java:37: error: cannot find symbol
          sum =(E + F);
          ^
  symbol:   variable sum
  location: class TravelingBudget
1 error
Language: C++

import java.util.Scanner;

class Ex1s6 {
    public static void main(String args[]) {
        int A;
        int B;
        int C;
        int D;
        Scanner sc = new Scanner(System.in);

        A = sc.nextInt();
        B = sc.nextInt();
        C = sc.nextInt();
        D = sc.nextInt();

        System.out.println(Math.min(A, B) + Math.min(C, D));
    }
}

Compiler output:
a.cc:1:1: error: 'import' does not name a type
    1 | import java.util.Scanner;
      | ^~~~~~
a.cc:1:1: note: C++20 'import' only available with '-fmodules-ts'
a.cc:4:11: error: expected ':' before 'static'
    4 |     public static void main(String args[]) {
      |           ^~~~~~~
      |           :
a.cc:4:29: error: 'String' has not been declared
    4 |     public static void main(String args[]) {
      |                             ^~~~~~
a.cc:18:2: error: expected ';' after class definition
   18 | }
      |  ^
      |  ;
a.cc: In static member function 'static void Ex1s6::main(int*)':
a.cc:9:9: error: 'Scanner' was not declared in this scope
    9 |         Scanner sc = new Scanner(System.in);
      |         ^~~~~~~
a.cc:11:13: error: 'sc' was not declared in this scope
   11 |         A = sc.nextInt();
      |             ^~
a.cc:16:9: error: 'System' was not declared in this scope
   16 |         System.out.println(Math.min(A, B) + Math.min(C, D));
      |         ^~~~~~
a.cc:16:28: error: 'Math' was not declared in this scope
   16 |         System.out.println(Math.min(A, B) + Math.min(C, D));
      |                            ^~~~
Language: C++

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

int main() {
  int a; 
  int b;
  int c;
  int d;
  
  cin >> a >> b >> c >> d ; 
  
  if ((a <= b) && (c <= d)){
    cout << a+c << endl;
  }
    else if ((a>b)&&(c<=d)){
      cout << b + c << emdl;
    }
      else if ((a >b) && (c > d)) {
        cout << b+d << endl;
      }
        else {
          cout << a+d<< endl;
        }
}
  
   
 




Compiler output:
a.cc: In function 'int main()':
a.cc:16:24: error: 'emdl' was not declared in this scope
   16 |       cout << b + c << emdl;
      |                        ^~~~