criyle/codenet-compile-errors huggingface dataset:
Language: Java

import java.util.Scanner;
 
class Main {
  public static void main(String[] args) {
    int saitan;
  	System.out.print("時間Pを入力してください：");
  	Scanner roadp = Scanner.nextInt();
    System.out.print("時間Qを入力してください：");
  	Scanner roadq = Scanner.nextInt();
  	System.out.print("時間Rを入力してください：");
    Scanner roadr = Scanner.nextInt();
    
    if (roadp > roadq) {
      saitan += roadq;
      	if (roadp > roadr) {
          saitan += roadr;
        }
    } else if (roadq > roadp) {
      saitan += roadp;
      	if (roadq > roadr) {
          saitan += roadr;
        } else if (roadr > roadp) {
          saitan += roadp;
          	if (roadr > roadq) {
              saitan += roadq;
            }
        }
    
    System.out.println("最短時間は" + saitan + "です");
    
    
  }
}

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

import java.util.Scanner;
 
class Main {
  public static void main(String args) {
    int saitan;
  	System.out.print("時間Pを入力してください：");
  	Scanner roadp = Scanner.nextInt();
    System.out.print("時間Qを入力してください：");
  	Scanner roadq = Scanner.nextInt();
  	System.out.print("時間Rを入力してください：");
    Scanner roadr = Scanner.nextInt();
    
    if (roadp > roadq) {
      saitan += roadq;
      	if (roadp > roadr) {
          saitan += roadr;
        }
    } else if (roadq > roadp) {
      saitan += roadp;
      	if (roadq > roadr) {
          saitan += roadr;
        } else if (roadr > roadp) {
          saitan += roadp;
          	if (roadr > roadq) {
              saitan += roadq;
            }
        }
    
    System.out.println("最短時間は" + saitan + "です");
    
    
  }
}

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

import java.util.Scanner;

class Main {
  public static void main(String args) {
    int saitan;
  	System.out.print("時間Pを入力してください：")
  	Scanner roadp = Scanner.nextInt();
    System.out.print("時間Qを入力してください：")
  	Scanner roadq = Scanner.nextInt();
  	System.out.print("時間Rを入力してください：")
    Scanner roadr = Scanner.nextInt();
    
    if (roadp > roadq) {
      saitan += roadq;
      	if (roadp > roadr) {
          saitan += roadr;
        }
    } else if (roadq > roadp) {
      saitan += roadp;
      	if (roadq > roadr) {
          saitan += roadr;
        } else if (roadr > roadp) {
          saitan += roadp;
          	if (roadr > roadq) {
              saitan += roadq;
            }
        }
    
    System.out.println("最短時間は" + saitan + "です");
    
    
  }
}

Compiler output:
Main.java:6: error: ';' expected
  	System.out.print("??P??????????")
  	                                 ^
Main.java:8: error: ';' expected
    System.out.print("??Q??????????")
                                     ^
Main.java:10: error: ';' expected
  	System.out.print("??R??????????")
  	                                 ^
Main.java:33: error: reached end of file while parsing
}
 ^
4 errors
Language: C++

#include <iostream>
int p;
int q;
int r;

int main()
{
	cin >> p >> q >> r;
	if (p <= r && q <= r)
		cout << p + q;
	else if (p <= q && r <= r)
		cout << p + r;
	else
		cout << q + r;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:9: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    8 |         cin >> p >> q >> r;
      |         ^~~
      |         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:10:17: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   10 |                 cout << p + q;
      |                 ^~~~
      |                 std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:12:17: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   12 |                 cout << p + r;
      |                 ^~~~
      |                 std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:14:17: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   14 |                 cout << q + r;
      |                 ^~~~
      |                 std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
Language: C

#include<stdio.h>

int main(void){
    int p,q,r;
    int a1,a2,a3;
    scanf("%d %d %d",&p,&q,&r);
    a1 = p + q;
    a2 = p + r;
    a3 = r + q;

    if( a1 < a2 && a2 < a3){
        printf("%d\n",a1);
    }else if( a2 < a1 && a1 < a3){
        printf("%d\n",a2);
    }else if( a3< a1 && a1 < a2 )
        printf("%d\n",a3);
    }

    return 0;
}

Compiler output:
main.c:19:5: error: expected identifier or '(' before 'return'
   19 |     return 0;
      |     ^~~~~~
main.c:20:1: error: expected identifier or '(' before '}' token
   20 | }
      | ^
Language: C

#include <stdio.h>
int main(void)
{
    int P, Q, R, x;
    scanf("%d %d %d", &P, &Q, &R);
    if (P < Q < R)
    {
        P + Q = x;
    }
    else if (P < R < Q)
    {
        P + Q = x;
    }
    else if (R < Q < P)
    {
        R + Q = x;
    }
    else if (R < P < Q)
    {
        R + P = x;
    }
    printf("%d", x);
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:8:15: error: lvalue required as left operand of assignment
    8 |         P + Q = x;
      |               ^
main.c:12:15: error: lvalue required as left operand of assignment
   12 |         P + Q = x;
      |               ^
main.c:16:15: error: lvalue required as left operand of assignment
   16 |         R + Q = x;
      |               ^
main.c:20:15: error: lvalue required as left operand of assignment
   20 |         R + P = x;
      |               ^
Language: C

int main(){

    int a[3],ans=200;

    for(int i=0;i<3;i++){
        cin>>a[i];
    }

    for(int i=0;i<2;i++){
        for(int j=n+1;j<3;j++){
            if(a[i]+a[j]<ans){
                ans=a[i]+a[j];
            }
        }
    }

    cout<<ans<<endl;

    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:6:9: error: 'cin' undeclared (first use in this function)
    6 |         cin>>a[i];
      |         ^~~
main.c:6:9: note: each undeclared identifier is reported only once for each function it appears in
main.c:10:19: error: 'n' undeclared (first use in this function)
   10 |         for(int j=n+1;j<3;j++){
      |                   ^
main.c:17:5: error: 'cout' undeclared (first use in this function)
   17 |     cout<<ans<<endl;
      |     ^~~~
main.c:17:16: error: 'endl' undeclared (first use in this function)
   17 |     cout<<ans<<endl;
      |                ^~~~
Language: C

#include<stdio.h>

int main(void){
    int list[3],i,p,q,r,min=100000;
    scanf("%d %d %d",&p,&q,&c);
    list[0]=p+q;
    list[1]=q+r;
    list[2]=r+p;
    for(i=0;i<3;i++){
        if(min>list[i]){
            min=list[i];
        }
    }
    printf("%d",min);
    return 0;
}


Compiler output:
main.c: In function 'main':
main.c:5:29: error: 'c' undeclared (first use in this function)
    5 |     scanf("%d %d %d",&p,&q,&c);
      |                             ^
main.c:5:29: note: each undeclared identifier is reported only once for each function it appears in
Language: C++

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

int main(){
  
  int P,Q,R;
  cin >> P >> Q >> R;
  
  int a = max(max(P,Q),R)
    
    cout << P+Q+R-a;
}
  
  

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

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

int main(){
  int P,Q,R;
  cin >> P >> Q >> R;
  if(P+Q >= P+R){
    if(P+R >=Q+R){
      cout << Q+R << endl;
    }
    else{
      cout << P+R << endl;
    }
  }
  if(P+R >= P+Q){
    if(P+Q >= Q+R){
      cout << Q+R << endl;
    }
    else{
      cout << P+Q <<rndl;
    }
  }
}

Compiler output:
a.cc:1:1: error: 'include' does not name a type
    1 | include <bits/stdc++.h>
      | ^~~~~~~
a.cc: In function 'int main()':
a.cc:6:3: error: 'cin' was not declared in this scope
    6 |   cin >> P >> Q >> R;
      |   ^~~
a.cc:9:7: error: 'cout' was not declared in this scope
    9 |       cout << Q+R << endl;
      |       ^~~~
a.cc:9:22: error: 'endl' was not declared in this scope
    9 |       cout << Q+R << endl;
      |                      ^~~~
a.cc:12:7: error: 'cout' was not declared in this scope
   12 |       cout << P+R << endl;
      |       ^~~~
a.cc:12:22: error: 'endl' was not declared in this scope
   12 |       cout << P+R << endl;
      |                      ^~~~
a.cc:17:7: error: 'cout' was not declared in this scope
   17 |       cout << Q+R << endl;
      |       ^~~~
a.cc:17:22: error: 'endl' was not declared in this scope
   17 |       cout << Q+R << endl;
      |                      ^~~~
a.cc:20:7: error: 'cout' was not declared in this scope
   20 |       cout << P+Q <<rndl;
      |       ^~~~
a.cc:20:21: error: 'rndl' was not declared in this scope
   20 |       cout << P+Q <<rndl;
      |                     ^~~~
Language: C++

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

int main() {
  int P,Q,R;
  cin >> P >> Q >> R;

  if (Q>R && R>P) {
    cout << P+R << endl;
  }


  if (R>P && P>Q ) {
    cout << P+Q << endl;
  }

  if (P>Q && Q>R) {
    cout << R+Q << endl;
  }
  
  if (Q=R && R=P && P=Q) {
    cout << P+R << endl;
  }
  
   if (Q=R && R>P) {
    cout << P+R << endl;
  }
  
   if (Q>R && R=P) {
    cout << P+R << endl;
  }
  
  if (P=R && R>Q) {
    cout << R+Q << endl;
  }
  
   if (P>R && R=Q) {
    cout << R+Q << endl;
  }
  
  if (R=Q && Q>P) {
    cout << Q+P << endl;
  }
  
   if (R>Q && Q=P) {
    cout << Q+P << endl;
  }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:21:18: error: lvalue required as left operand of assignment
   21 |   if (Q=R && R=P && P=Q) {
      |                ~~^~~~
a.cc:29:12: error: lvalue required as left operand of assignment
   29 |    if (Q>R && R=P) {
      |        ~~~~^~~~
a.cc:37:12: error: lvalue required as left operand of assignment
   37 |    if (P>R && R=Q) {
      |        ~~~~^~~~
a.cc:45:12: error: lvalue required as left operand of assignment
   45 |    if (R>Q && Q=P) {
      |        ~~~~^~~~
Language: C++

#include<iostream>
#include<cstdlib>
#include<istream>
#include <stdio.h>
#include<vector>
#include <fstream>
#include <string>
#include<stdio.h>
int main() {
	int P, Q, R,M;
	cin >> P >> Q >> R;
	 if (P + Q > Q + R) {
		 M = P + Q;
	 }
	 else {
		 M = Q + R;
	 }
	 if (M > P + R) {}
	 else {
		 M = P + R;
		 }
	 cout<<M;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:9: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
   11 |         cin >> P >> Q >> R;
      |         ^~~
      |         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:22:10: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   22 |          cout<<M;
      |          ^~~~
      |          std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
Language: C

#include<stdio.h>
int main(void){
    int P, Q, R;
    scanf("%d %d %d",&P, &Q, &R);
    if(P < Q < R){
        printf("%d",P + Q);
    }if else(Q < R < P){
        printf("%d",Q + R);
    }if else(R < P < Q){
        printf("%d",R + P);
    }
return 0;
}

Compiler output:
main.c: In function 'main':
main.c:7:9: error: expected '(' before 'else'
    7 |     }if else(Q < R < P){
      |         ^~~~
      |         (
Language: C++

#include<iostream>
using namespace std;
signed main(){
  int a[3],b[3],c;
  for(int i=0;i<3;i++){
    cin>>a[i];
  }
  sort(a,a+3);
  for(int i=0;i<3;i++){
    b[i]=a[i];
    }
  c=b[0]+b[1];
  cout<<c<<"\n";
  return(0);
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:3: error: 'sort' was not declared in this scope; did you mean 'short'?
    8 |   sort(a,a+3);
      |   ^~~~
      |   short
Language: C++

#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef unsigned long long ull;
int main()
{
	int a,b,c;
	cin>>a>>b>>c;
	cout<<min(a+b,min(b+c,a+c)) 
	return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:9:36: error: expected ';' before 'return'
    9 |         cout<<min(a+b,min(b+c,a+c))
      |                                    ^
      |                                    ;
   10 |         return 0;
      |         ~~~~~~
Language: Java

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

public class Main {
  
	public static void main(String[] args){
      	Scanner in = new Scanner(System.in);
		int Ph = in.nextInt();
      	int Qh = in.nextInt();
      	int Rh = in.nextInt();
      
      	System.out.println(minSumBetween(Ph,Qh,Rh));
      
	}
  
  	public int minSumBetween(int a,int b,int c){
    	if(a<b){
        	if(b<c) return a+b;
          	else return a+c;
        }else{
        	if(a<c) return b+a;
          	else return b+c;
        }
    }
}

Compiler output:
Main.java:12: error: non-static method minSumBetween(int,int,int) cannot be referenced from a static context
      	System.out.println(minSumBetween(Ph,Qh,Rh));
      	                   ^
1 error
Language: C++

#include<iostream>
using namespace std;
signed main(){
  int a[6],b[6],c;
  for(int i=0;i<3;i++){
    cin>>a[i];
  }
  sort(a,a+3);
  for(int i=0;i<3;i++){
    b[i]=a[i];
    }
  c=b[0]+b[1];
  cout<<c<<"\n";
  return(0);
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:3: error: 'sort' was not declared in this scope; did you mean 'short'?
    8 |   sort(a,a+3);
      |   ^~~~
      |   short
Language: C++

#include<iostream>
using namespace std;
int a[3];
int main()
{
  for(int i=0;i<3;i++)
    cin>>a[i];
  sort(a,a+3);
  cout<<a[0]+a[1]<<endl;
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:3: error: 'sort' was not declared in this scope; did you mean 'short'?
    8 |   sort(a,a+3);
      |   ^~~~
      |   short
Language: C

#include<stdio.h>
int main(void){
    int P, Q, R;
    scanf("%d %d %d",&P, &Q, &R);
    if(P < Q < R){
        printf("%d",P + Q);
    }if else(Q < R < P){
        printf("%d",Q + R);
    }if else(R < P < Q){
        printf("%d",R + P);
    }
  return 0;
} 

Compiler output:
main.c: In function 'main':
main.c:7:9: error: expected '(' before 'else'
    7 |     }if else(Q < R < P){
      |         ^~~~
      |         (
Language: C

#include<iostream>
using namespace std;
signed main(){
  int a[6],b[6],c;
  for(int i=0;i<3;i++){
    cin>>a[i];
  }
  sort(a,a+3);
  for(int i=0;i<3;i++){
    b[i]=a[i];
    }
  c=b[0]+b[1];
  cout<<c<<"\n";
  return(0);
}

Compiler output:
main.c:1:9: fatal error: iostream: No such file or directory
    1 | #include<iostream>
      |         ^~~~~~~~~~
compilation terminated.
Language: C++

#include <bits/stdc++.h>
using namespace std;
 
int main() {
  int P,Q,R;
  cin >> P >> Q >> R;
 
  if(R => P && R => Q)
  {
    cout << P + Q << endl;
  }
  else if(Q => P && Q => R)
  {
    cout << P + R << endl;
  }
  else
  {
    cout << Q + R << endl;
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:9: error: expected primary-expression before '>' token
    8 |   if(R => P && R => Q)
      |         ^
a.cc:8:19: error: expected primary-expression before '>' token
    8 |   if(R => P && R => Q)
      |                   ^
a.cc:12:14: error: expected primary-expression before '>' token
   12 |   else if(Q => P && Q => R)
      |              ^
a.cc:12:24: error: expected primary-expression before '>' token
   12 |   else if(Q => P && Q => R)
      |                        ^
Language: C++

#include<iostream>
#include<vector>
using namespace std;
int main() {
		int a, b, c;
		std::cin >> a, b, c;
		int x = a+b;
		int y = a + c ;
        int z = b+c;
        vector<int> V;
        V.push_back(x);
        V.push_back(y);
        V.push_back(z);
        sort(V.begin(), V.end());
		std::cout << V[0] << std::endl;
	}

Compiler output:
a.cc: In function 'int main()':
a.cc:14:9: error: 'sort' was not declared in this scope; did you mean 'short'?
   14 |         sort(V.begin(), V.end());
      |         ^~~~
      |         short
Language: C

#include<stdio.h>
int Air(int a, int b, int c){
  int A = a + b;
  int B = a + c;
  int C = b + c;
  
   min = A;
   if(B < min)
  min = B;
  if(C < min)
  min = C;
  return C;
}

int main(){
  int P,Q,R;
  scanf("%d %d %d", &P, &Q, &R );
  printf("%d" , Air(P,Q,R));

  return 0;
}

Compiler output:
main.c: In function 'Air':
main.c:7:4: error: 'min' undeclared (first use in this function)
    7 |    min = A;
      |    ^~~
main.c:7:4: note: each undeclared identifier is reported only once for each function it appears in
Language: C++

#include <stdio.h>
#include <algorithm>
#include <string>
#include <vector>



int main() {
	int P, Q, R;
	scanf("%d %d %d", &P, &Q, &R);
	int res = P + Q + R - std::max(std::P, max(Q, R));
	printf("%d", res);
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:45: error: 'P' is not a member of 'std'
   11 |         int res = P + Q + R - std::max(std::P, max(Q, R));
      |                                             ^
a.cc:11:48: error: 'max' was not declared in this scope; did you mean 'std::max'?
   11 |         int res = P + Q + R - std::max(std::P, max(Q, R));
      |                                                ^~~
      |                                                std::max
In file included from /usr/include/c++/14/algorithm:61,
                 from a.cc:2:
/usr/include/c++/14/bits/stl_algo.h:5716:5: note: 'std::max' declared here
 5716 |     max(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
Language: Java

import java.util.*;

 
class Main {
  public static void main(String args[]) {
    Scanner scanner = new Scanner(System.in);
    String input = scanner.nextInt();
    String input2 = scanner.nextInt();
    String input3 = scanner.nextInt();
    scanner.close();
    int a = input + input2;
    int b = input2 + input3;
    int c = input3 + input;
    int alpha = Math.min(a,b);
    int beta = Math.min(alpha,c);
    System.out.println(beta);
  }
}


Compiler output:
Main.java:7: error: incompatible types: int cannot be converted to String
    String input = scanner.nextInt();
                                  ^
Main.java:8: error: incompatible types: int cannot be converted to String
    String input2 = scanner.nextInt();
                                   ^
Main.java:9: error: incompatible types: int cannot be converted to String
    String input3 = scanner.nextInt();
                                   ^
Main.java:11: error: incompatible types: String cannot be converted to int
    int a = input + input2;
                  ^
Main.java:12: error: incompatible types: String cannot be converted to int
    int b = input2 + input3;
                   ^
Main.java:13: error: incompatible types: String cannot be converted to int
    int c = input3 + input;
                   ^
6 errors
Language: C

#include<stdio.h>
int main(void){
    int P, Q, R;
    scanf("%d %d %d",&P, &Q, &R);
    if(P < Q < R){
        printf("%d",P + Q);
    }ifelse(Q < R < P){
        printf("%d",Q + R);
    }ifelse(R < P < Q){
        printf("%d",R + P);
    }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:7:6: error: implicit declaration of function 'ifelse' [-Wimplicit-function-declaration]
    7 |     }ifelse(Q < R < P){
      |      ^~~~~~
main.c:7:23: error: expected ';' before '{' token
    7 |     }ifelse(Q < R < P){
      |                       ^
      |                       ;
Language: C++

#include <stdio.h>
#include <algorithm>
#include <string>
#include <vector>



int main() {
	int P, Q, R;
	scanf("%d %d %d", &P, &Q, &R);
	int res = P + Q + R - max(P, max(Q, R));
	printf("%d", res);
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:38: error: 'max' was not declared in this scope; did you mean 'std::max'?
   11 |         int res = P + Q + R - max(P, max(Q, R));
      |                                      ^~~
      |                                      std::max
In file included from /usr/include/c++/14/algorithm:61,
                 from a.cc:2:
/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:11:31: error: 'max' was not declared in this scope; did you mean 'std::max'?
   11 |         int res = P + Q + R - max(P, max(Q, R));
      |                               ^~~
      |                               std::max
/usr/include/c++/14/bits/stl_algo.h:5716:5: note: 'std::max' declared here
 5716 |     max(initializer_list<_Tp> __l, _Compare __comp)
      |     ^~~
Language: Java

import java.util.*;

 
class Main {
  public static void main(String args[]) {
    Scanner scanner = new Scanner(System.in);
    String input = scanner.nextInt();
    String input2 = scanner.nextInt();
    String input3 = scanner.nextInt();
    scanner.close();
    int a = input + input2;
    int b = input2 + input3;
    int c = input3 + input;
    int alpha = Math.min(a,b);
    int beta = Math.min(alpha,c);
    System.out.println(beta)
  }
}


Compiler output:
Main.java:16: error: ';' expected
    System.out.println(beta)
                            ^
1 error
Language: C

#include<stdio.h>
int main(void){
    int P, Q, R;
    scanf("%d %d %d",&P, &Q, &R);
    if(P < Q < R){
        printf("%d",P + Q);
    }if else(Q < R < P){
        printf("%d",Q + R);
    }else{
        printf("%d",R + P);
    }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:7:9: error: expected '(' before 'else'
    7 |     }if else(Q < R < P){
      |         ^~~~
      |         (
Language: C++

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

int P,Q,R;
int main(){
  cin >>P >>Q >>R;
  cout << std::min(P+Q,Q+R,R+P)
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:32: error: expected ';' before 'return'
   10 |   cout << std::min(P+Q,Q+R,R+P)
      |                                ^
      |                                ;
   11 |   return 0;
      |   ~~~~~~                        
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::min(const _Tp&, const _Tp&, _Compare) [with _Tp = int; _Compare = int]':
a.cc:10:19:   required from here
   10 |   cout << std::min(P+Q,Q+R,R+P)
      |           ~~~~~~~~^~~~~~~~~~~~~
/usr/include/c++/14/bits/stl_algobase.h:284:17: error: '__comp' cannot be used as a function
  284 |       if (__comp(__b, __a))
      |           ~~~~~~^~~~~~~~~~
Language: C++

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

using namespace std;

int main(int argc, char const *argv[])
{
  vector<int> length(3);
  for (int i = 0; i < 3; ++i)
  {
    cin >> length[i];
  }
  sort(length.begin(), length.end());
  cout << length[0] + length[1] << endl;
  return 0;
}

Compiler output:
a.cc: In function 'int main(int, const char**)':
a.cc:14:3: error: 'sort' was not declared in this scope; did you mean 'short'?
   14 |   sort(length.begin(), length.end());
      |   ^~~~
      |   short
Language: C

input_data=input().split()

P=int(input_data[0])
Q=int(input_data[1])
R=int(input_data[2])

abc = P+Q
acb = R+Q
bac = P+R
bca = Q+R
cab = R+P
cba = Q+P

answer=min(abc,acb,bac,bca,cab,cba)
print(answer)

Compiler output:
main.c:1:1: warning: data definition has no type or storage class
    1 | input_data=input().split()
      | ^~~~~~~~~~
main.c:1:1: error: type defaults to 'int' in declaration of 'input_data' [-Wimplicit-int]
main.c:1:12: error: implicit declaration of function 'input' [-Wimplicit-function-declaration]
    1 | input_data=input().split()
      |            ^~~~~
main.c:1:19: error: request for member 'split' in something not a structure or union
    1 | input_data=input().split()
      |                   ^
main.c:3:1: error: expected ',' or ';' before 'P'
    3 | P=int(input_data[0])
      | ^
Language: Java

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

public class Main {
	
	static InputReader in = new InputReader(System.in);

	public static void main(String[] args){
		int Ph = in.nextInt();
      	int Qh = in.nextInt();
      	int Rh = in.nextInt();
      
      	if(Ph<Qh && Qh < Rh){ System.out.println(Ph+Qh); }
        if(Ph<Rh && Rh < Qh){ System.out.println(Ph+Rh); }
      	if(Qh<Ph && Ph < Rh){ System.out.println(Qh+Ph); }
      	if(Qh<Rh && Rh < Ph){ System.out.println(Qh+Rh); }
      	if(Rh<Ph && Ph < Qh){ System.out.println(Rh+Ph); }
      	if(Rh<Qh && Qh < Ph){ System.out.println(Rh+Qh); }
      
	}
}


	


Compiler output:
Main.java:6: error: cannot find symbol
	static InputReader in = new InputReader(System.in);
	       ^
  symbol:   class InputReader
  location: class Main
Main.java:6: error: cannot find symbol
	static InputReader in = new InputReader(System.in);
	                            ^
  symbol:   class InputReader
  location: class Main
2 errors
Language: C

int min;
 
  scanf("%d %d %d", &P, &Q, &R);
  
  X = P + Q;
  Y = Q + R;
  Z = R + P;
  
  min = X;
  if(Y < min) min = Y;
  if(Z < min) min = Z;
  
  printf("%d", min);
  return 0;
}

Compiler output:
main.c:3:9: error: expected declaration specifiers or '...' before string constant
    3 |   scanf("%d %d %d", &P, &Q, &R);
      |         ^~~~~~~~~~
main.c:3:21: error: expected declaration specifiers or '...' before '&' token
    3 |   scanf("%d %d %d", &P, &Q, &R);
      |                     ^
main.c:3:25: error: expected declaration specifiers or '...' before '&' token
    3 |   scanf("%d %d %d", &P, &Q, &R);
      |                         ^
main.c:3:29: error: expected declaration specifiers or '...' before '&' token
    3 |   scanf("%d %d %d", &P, &Q, &R);
      |                             ^
main.c:5:3: warning: data definition has no type or storage class
    5 |   X = P + Q;
      |   ^
main.c:5:3: error: type defaults to 'int' in declaration of 'X' [-Wimplicit-int]
main.c:5:7: error: 'P' undeclared here (not in a function)
    5 |   X = P + Q;
      |       ^
main.c:5:11: error: 'Q' undeclared here (not in a function)
    5 |   X = P + Q;
      |           ^
main.c:6:3: warning: data definition has no type or storage class
    6 |   Y = Q + R;
      |   ^
main.c:6:3: error: type defaults to 'int' in declaration of 'Y' [-Wimplicit-int]
main.c:6:11: error: 'R' undeclared here (not in a function)
    6 |   Y = Q + R;
      |           ^
main.c:7:3: warning: data definition has no type or storage class
    7 |   Z = R + P;
      |   ^
main.c:7:3: error: type defaults to 'int' in declaration of 'Z' [-Wimplicit-int]
main.c:9:3: warning: data definition has no type or storage class
    9 |   min = X;
      |   ^~~
main.c:9:3: error: type defaults to 'int' in declaration of 'min' [-Wimplicit-int]
main.c:9:9: error: initializer element is not constant
    9 |   min = X;
      |         ^
main.c:10:3: error: expected identifier or '(' before 'if'
   10 |   if(Y < min) min = Y;
      |   ^~
main.c:11:3: error: expected identifier or '(' before 'if'
   11 |   if(Z < min) min = Z;
      |   ^~
main.c:13:10: error: expected declaration specifiers or '...' before string constant
   13 |   printf("%d", min);
      |          ^~~~
main.c:13:16: error: expected declaration specifiers or '...' before 'min'
   13 |   printf("%d", min);
      |                ^~~
main.c:14:3: error: expected identifier or '(' before 'return'
   14 |   return 0;
      |   ^~~~~~
main.c:15:1: error: expected identifier or '(' before '}' token
   15 | }
      | ^
Language: C

#include<stdio.h>
int main(void){
    int P, Q, R;
    scanf("%d %d %d",&P, &Q, &R);
    if(P < Q < R){
        printf("%d",P + Q);
    }if else(Q < R < P){
        printf("%d",Q + R);
    }if else(R < P < Q){
        printf("%d",R + P);
    }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:7:9: error: expected '(' before 'else'
    7 |     }if else(Q < R < P){
      |         ^~~~
      |         (
Language: Java

public class Main {
	
	static InputReader in = new InputReader(System.in);

	public static void main(String[] args){
		int Ph = in.nextInt();
      	int Qh = in.nextInt();
      	int Rh = in.nextInt();
      
      	if(Ph<Qh && Qh < Rh){ System.out.println(Ph+Qh); }
        if(Ph<Rh && Rh < Qh){ System.out.println(Ph+Rh); }
      	if(Qh<Ph && Ph < Rh){ System.out.println(Qh+Ph); }
      	if(Qh<Rh && Rh < Ph){ System.out.println(Qh+Rh); }
      	if(Rh<Ph && Ph < Qh){ System.out.println(Rh+Ph); }
      	if(Rh<Qh && Qh < Ph){ System.out.println(Rh+Qh); }
      
	}
}

class InputReader {

	private final InputStream stream;
	private final byte[] buf = new byte[8192];
	private int curChar, snumChars;

	public InputReader(InputStream st) {
		this.stream = st;
	}

	public int nextInt() {
		int c = read();
		while (isSpaceChar(c)) {
			c = read();
		}
		int sgn = 1;
		if (c == '-') {
			sgn = -1;
			c = read();
		}
		int res = 0;
		do {
			res *= 10;
			res += c - '0';
			c = read();
		} while (!isSpaceChar(c));
		return res * sgn;
	}
}
	
	


Compiler output:
Main.java:22: error: cannot find symbol
	private final InputStream stream;
	              ^
  symbol:   class InputStream
  location: class InputReader
Main.java:26: error: cannot find symbol
	public InputReader(InputStream st) {
	                   ^
  symbol:   class InputStream
  location: class InputReader
Main.java:31: error: cannot find symbol
		int c = read();
		        ^
  symbol:   method read()
  location: class InputReader
Main.java:32: error: cannot find symbol
		while (isSpaceChar(c)) {
		       ^
  symbol:   method isSpaceChar(int)
  location: class InputReader
Main.java:33: error: cannot find symbol
			c = read();
			    ^
  symbol:   method read()
  location: class InputReader
Main.java:38: error: cannot find symbol
			c = read();
			    ^
  symbol:   method read()
  location: class InputReader
Main.java:44: error: cannot find symbol
			c = read();
			    ^
  symbol:   method read()
  location: class InputReader
Main.java:45: error: cannot find symbol
		} while (!isSpaceChar(c));
		          ^
  symbol:   method isSpaceChar(int)
  location: class InputReader
8 errors
Language: C++

#include<iostream>
using namespace std;
int main(){
int p,q,r;
  cin>>p>>q>>r;
  if(p<q){
	if(r<q){
cout<<p+r<<endl;
    }else{
cout<<p+q<<endl;
    }
  }else{
if(r<p){
  cout<<r+q<<endl;
  }else{
cout<<q+p<<endl;
}
  }

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

public class Main {
	
	static Scanner in = new Scanner(System.in);

	public static void main(String[] args) throws IOException {
		int Ph = in.nextInt();
      	int Qh = in.nextInt();
      	int Rh = in.nextInt();
      
      	if(Ph<Qh && Qh < Rh){ System.out.println(Ph+Qh); }
        if(Ph<Rh && Rh < Qh){ System.out.println(Ph+Rh); }
      	if(Qh<Ph && Ph < Rh){ System.out.println(Qh+Ph); }
      	if(Qh<Rh && Rh < Ph){ System.out.println(Qh+Rh); }
      	if(Rh<Ph && Ph < Qh){ System.out.println(Rh+Ph); }
      	if(Rh<Qh && Qh < Ph){ System.out.println(Rh+Qh); }
      
	}
}
	
	


Compiler output:
Main.java:3: error: cannot find symbol
	static Scanner in = new Scanner(System.in);
	       ^
  symbol:   class Scanner
  location: class Main
Main.java:5: error: cannot find symbol
	public static void main(String[] args) throws IOException {
	                                              ^
  symbol:   class IOException
  location: class Main
Main.java:3: error: cannot find symbol
	static Scanner in = new Scanner(System.in);
	                        ^
  symbol:   class Scanner
  location: class Main
3 errors
Language: Java

public class Main {
	
	static Scanner in = new Scanner(System.in);

	public static void main(String[] args) throws IOException {
		int Ph = in.nextInt();
      	int Qh = in.nextInt();
      	int Rh = in.nextInt();
      
      	if(Ph<Qh && Qh < Rh){ System.out.println(Ph+Qh) }
        if(Ph<Rh && Rh < Qh){ System.out.println(Ph+Rh) }
      	if(Qh<Ph && Ph < Rh){ System.out.println(Qh+Ph) }
      	if(Qh<Rh && Rh < Ph){ System.out.println(Qh+Rh) }
      	if(Rh<Ph && Ph < Qh){ System.out.println(Rh+Ph) }
      	if(Rh<Qh && Qh < Ph){ System.out.println(Rh+Qh) }
      
	}
}
	
	

Compiler output:
Main.java:10: error: ';' expected
      	if(Ph<Qh && Qh < Rh){ System.out.println(Ph+Qh) }
      	                                               ^
Main.java:11: error: ';' expected
        if(Ph<Rh && Rh < Qh){ System.out.println(Ph+Rh) }
                                                       ^
Main.java:12: error: ';' expected
      	if(Qh<Ph && Ph < Rh){ System.out.println(Qh+Ph) }
      	                                               ^
Main.java:13: error: ';' expected
      	if(Qh<Rh && Rh < Ph){ System.out.println(Qh+Rh) }
      	                                               ^
Main.java:14: error: ';' expected
      	if(Rh<Ph && Ph < Qh){ System.out.println(Rh+Ph) }
      	                                               ^
Main.java:15: error: ';' expected
      	if(Rh<Qh && Qh < Ph){ System.out.println(Rh+Qh) }
      	                                               ^
6 errors
Language: C

#include <stdio.h>
int main(){
  int ps[3];
  int i,j,m;
  scanf("%d %d %d",&ps[0],&ps[1],&ps[2]);
  s=ps[0];
  if(ps[1]>=s)s=ps[1];
  if(ps[2]>=s)s=ps[2];
  m=ps[0]+ps[1]+ps[2]-s;
  printf("%d\n",m);
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:6:3: error: 's' undeclared (first use in this function)
    6 |   s=ps[0];
      |   ^
main.c:6:3: note: each undeclared identifier is reported only once for each function it appears in
Language: C++

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

int main() {
  int P,Q,R;
  cin >> P >> Q >> R;

  if (Q>=R && Q>=P) {
    cout << P+R << endl;
  }

  if (R>=P && R>=Q ) {
    cout << P+Q << endl;
  }

  if (P>=Q && P>=R) {
    cout << R+Q << endl;
    ｝
｝


Compiler output:
a.cc: In function 'int main()':
a.cc:18:5: error: '\U0000ff5d' was not declared in this scope
   18 |     ｝
      |     ^~
a.cc:19:3: error: expected '}' at end of input
   19 | ｝
      |   ^
a.cc:16:21: note: to match this '{'
   16 |   if (P>=Q && P>=R) {
      |                     ^
a.cc:19:3: error: expected '}' at end of input
   19 | ｝
      |   ^
a.cc:4:12: note: to match this '{'
    4 | int main() {
      |            ^
Language: C++

#include <iostream>
#include <vector>
using namespace std;
int main()
{
   int p,q,r;
   cin >> p >> q >> r;
int hai[]={p+q,p+r,q+r};
    int i;
    int min;
    int max;
    int ans;
 
    /* 代入 */
    min=hai[0];
    max=hai[0];
    ans=0;
 
    /* 計算 */
    for(i=0;i<=2;i++){/* 最大値求める */
        if(hai[i]>max)
        max=hai[i];
        /* 最小値求める */
        if(hai[i]<min)

Compiler output:
a.cc: In function 'int main()':
a.cc:24:23: error: expected statement at end of input
   24 |         if(hai[i]<min)
      |                       ^
a.cc:24:23: error: expected '}' at end of input
a.cc:20:22: note: to match this '{'
   20 |     for(i=0;i<=2;i++){/* 最大値求める */
      |                      ^
a.cc:24:23: error: expected '}' at end of input
   24 |         if(hai[i]<min)
      |                       ^
a.cc:5:1: note: to match this '{'
    5 | {
      | ^
Language: C++

#include <bits/stdc++.h>
using namespace std;
int mx(int a,int b,int c){
  int d,e;
  d=max(a,b);
  e=max(d,c);
  return e;
int main(){
  int a,b,c,sum,x;
  cin>>a>>b>>c;
  sum=a+b+c;
  x=sum-mx(a,b,c);
  cout<<x;
  return 0;
}

Compiler output:
a.cc: In function 'int mx(int, int, int)':
a.cc:8:9: warning: empty parentheses were disambiguated as a function declaration [-Wvexing-parse]
    8 | int main(){
      |         ^~
a.cc:8:9: note: remove parentheses to default-initialize a variable
    8 | int main(){
      |         ^~
      |         --
a.cc:8:9: note: or replace parentheses with braces to value-initialize a variable
a.cc:8:11: error: a function-definition is not allowed here before '{' token
    8 | int main(){
      |           ^
a.cc:15:2: error: expected '}' at end of input
   15 | }
      |  ^
a.cc:3:26: note: to match this '{'
    3 | int mx(int a,int b,int c){
      |                          ^
Language: Java

class Main{
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        int P = sc.nextInt();
        int Q = sc.nextInt();
        int R = sc.nextInt();
        int ans;

        ans = P+Q;

        if(ans >= Q+R){
            ans = Q + R;
        }
        if(ans >= R+P){
            ans = R + P;
        }

        System.out.println(ans);
    }
}

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

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

int main() {
  int P,Q,R;
  cin >> P >> Q >> R;

  if (Q>=R && Q>=P) {
    cout << P+R << endl;
  }

  if (R>=P && R>=Q ) {
    cout << P+Q << endl;
  }

  if (P>=Q && P>=R) {
    cout << R+Q << endl;｝
｝


Compiler output:
a.cc: In function 'int main()':
a.cc:17:25: error: '\U0000ff5d' was not declared in this scope
   17 |     cout << R+Q << endl;｝
      |                         ^~
a.cc:18:3: error: expected '}' at end of input
   18 | ｝
      |   ^
a.cc:16:21: note: to match this '{'
   16 |   if (P>=Q && P>=R) {
      |                     ^
a.cc:18:3: error: expected '}' at end of input
   18 | ｝
      |   ^
a.cc:4:12: note: to match this '{'
    4 | int main() {
      |            ^
Language: C

#include <stdio.h>

int main(void)
	{
		int P,Q,R,a,b,c;
		
		scanf_s("%d %d %d", &P, &Q, &R);
		a = P + R;
		b = P + Q;
		c = Q + R;
		if (b <= a) 
		{
			if (b <= c) {
				printf("%d", b);
			}
			else
			{
				printf("%d", c);
			}
		}
		else 
		{
			if (a <= c) {
				printf("%d", a);
			}
			else {
				printf("%d", c);
			}
		}
		return 0;
	}

Compiler output:
main.c: In function 'main':
main.c:7:17: error: implicit declaration of function 'scanf_s'; did you mean 'scanf'? [-Wimplicit-function-declaration]
    7 |                 scanf_s("%d %d %d", &P, &Q, &R);
      |                 ^~~~~~~
      |                 scanf
Language: C++

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

int main(){
  vector<int> vec(3);
  vector<int> wa(4);
  int answer;
  
  for(int i = 0;i < 3;i++){
    cin >> vec.at(i);
  }
  
  wa.at(0) = vec.at(0) + vec.at(1);
  wa.at(1) = vec.at(0) + vec.at(2);
  wa.at(2) = vec.at(1) + vec.at(2);
  wa.at(3) = wa.at(0)
  
  for(int i =0;i < 3;i++){
    if(wa.at(i) >= wa.at(i + 1)){
      answer = wa. at(i);
    }
  }
  
  cout << answer;
  
  

Compiler output:
a.cc: In function 'int main()':
a.cc:17:22: error: expected ';' before 'for'
   17 |   wa.at(3) = wa.at(0)
      |                      ^
      |                      ;
   18 | 
   19 |   for(int i =0;i < 3;i++){
      |   ~~~                 
a.cc:19:16: error: 'i' was not declared in this scope
   19 |   for(int i =0;i < 3;i++){
      |                ^
a.cc:25:18: error: expected '}' at end of input
   25 |   cout << answer;
      |                  ^
a.cc:5:11: note: to match this '{'
    5 | int main(){
      |           ^
Language: C++

<!– caution -->

推定クリア率0.1%！
企業からの依頼クエストをクリアすると
書類選考なしの特別選考枠にご招待！？
#エンジニア採用RPG 公開中！

▼第１弾「魔王をハッキングせよ」
https://t.co/82kyuUgVJz
#コードクエスト

Compiler output:
a.cc:1:3: error: extended character – is not valid in an identifier
    1 | <!– caution -->
      |   ^
a.cc:6:2: error: invalid preprocessing directive #\U000030a8\U000030f3\U000030b8\U000030cb\U000030a2\U000063a1\U00007528RPG
    6 | #エンジニア採用RPG 公開中！
      |  ^~~~~~~~~~~~~~~~~
a.cc:8:1: error: extended character ▼ is not valid in an identifier
    8 | ▼第１弾「魔王をハッキングせよ」
      | ^
a.cc:8:1: error: extended character 「 is not valid in an identifier
a.cc:8:1: error: extended character 」 is not valid in an identifier
a.cc:10:2: error: invalid preprocessing directive #\U000030b3\U000030fc\U000030c9\U000030af\U000030a8\U000030b9\U000030c8
   10 | #コードクエスト
      |  ^~~~~~~~~~~~~~
a.cc:1:1: error: expected unqualified-id before '<' token
    1 | <!– caution -->
      | ^
Language: C++

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

int main(){
  int p, q, r, x;
  cin >> p >> q >> r;
  x = max(p, q, r);
  cout << p + q + r - x <<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:7:10:   required from here
    7 |   x = max(p, q, r);
      |       ~~~^~~~~~~~~
/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(void){
    // Your code here!
    int P, Q, R, ab, pq, qr, pr;
    cin >> P >> Q >> R;
    pq = P + Q;
    qr = Q + R;
    pr = P + R;
    if(pq <= pr && pq <= qr) {
        cout << pq << endl;
    } else if(pr <= pq && pr <= qr) {
        cout << pr << endl;
    }else {
        cout << qr << 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 P,Q,R;
  cin >> P >> Q >> R;

  if (Q>=R && Q>=P) {
    cout << P+R << endl;
  }

  if (R>=P && R>=Q ) {
    cout << P+Q << endl;
  }

  if (P>=Q && P>=R) {
    cout << R+Q << endl;
｝


Compiler output:
a.cc: In function 'int main()':
a.cc:18:1: error: '\U0000ff5d' was not declared in this scope
   18 | ｝
      | ^~
a.cc:18:3: error: expected '}' at end of input
   18 | ｝
      |   ^
a.cc:16:21: note: to match this '{'
   16 |   if (P>=Q && P>=R) {
      |                     ^
a.cc:18:3: error: expected '}' at end of input
   18 | ｝
      |   ^
a.cc:4:12: note: to match this '{'
    4 | int main() {
      |            ^
Language: C++

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

Compiler output:
a.cc:1:1: error: 'include' does not name a type
    1 | include<bits/stdc++.h>
      | ^~~~~~~
a.cc: In function 'int main()':
a.cc:6:3: error: 'cin' was not declared in this scope
    6 |   cin>>a>>b>>c;
      |   ^~~
a.cc:7:5: error: 'min' was not declared in this scope; did you mean 'main'?
    7 |   x=min(a+b,a+c);
      |     ^~~
      |     main
a.cc:9:3: error: 'cout' was not declared in this scope
    9 |   cout<<x;
      |   ^~~~
Language: C++

#include<iostream>
#include <math.h>
#include <algorithm>
#include<queue>
#include <bits/stdc++.h>


using namespace std;

#define FOR(i,a,b) for(int i=(a),i##formax=(b);i<i##formax;i++)

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

Compiler output:
a.cc:12:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
   12 | main(){
      | ^~~~
a.cc: In function 'int main()':
a.cc:22:24: error: expected primary-expression before ',' token
   22 |     else {cout << b+c ,,endl; }
      |                        ^
Language: C++

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





int main(){
	int P=0;
	int Q=0;
	int R=0;
	cin>>P>>Q>>R;
	int ans;
	int a,b,c;
	a=P+Q;
	b=Q+R;
	c=R+P;
	vector<int>t(4);

	t[0]=a;
	t[1]=b;
	t[2]=c;
	ans =a;
	for(i=1;i<3;i++){
		if(ans>t[i]){
			ans=t[i];
		}
	}
	cout<<ans;



	
}


Compiler output:
a.cc: In function 'int main()':
a.cc:24:13: error: 'i' was not declared in this scope
   24 |         for(i=1;i<3;i++){
      |             ^
Language: C++

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

int main() {
  int P,Q,R;
  int ans-0;
  cin >> P >> Q >> R;
  if (P+R<Q+P && P+R<Q+R ){
     ans += P+R;
  }
  else if (Q+R<P+R && Q+R<P+Q){
     ans += Q+R;
  }
  else if (P+Q<Q+R && P+Q<P+R){
     ans += P+Q;
  }
  cout << ans << endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:6:10: error: expected initializer before '-' token
    6 |   int ans-0;
      |          ^
a.cc:9:6: error: 'ans' was not declared in this scope; did you mean 'abs'?
    9 |      ans += P+R;
      |      ^~~
      |      abs
a.cc:12:6: error: 'ans' was not declared in this scope; did you mean 'abs'?
   12 |      ans += Q+R;
      |      ^~~
      |      abs
a.cc:15:6: error: 'ans' was not declared in this scope; did you mean 'abs'?
   15 |      ans += P+Q;
      |      ^~~
      |      abs
a.cc:17:11: error: 'ans' was not declared in this scope; did you mean 'abs'?
   17 |   cout << ans << endl;
      |           ^~~
      |           abs
Language: C++

#include<iostream>
#include <algorithm>
#include <vector>
using namespace std;
int main(){
  int P,Q,R;
  vector<int> sum;
  cin >> P;
  cin >> Q;
  cin >> R;
  sum.push_back(P+Q);
  sum.push_back(Q+R);
  sum.push_back(R+P);
  sort(v.begin(), v.end(), std::greater<int>() );
  cout << v.begin() << endl;
  return 0;
}
#include<iostream>
#include <algorithm>
using namespace std;
int main(){
  int P,Q,R;
  vector<int> sum;
  cin >> P;
  cin >> Q;
  cin >> R;
  sum.push_back(P+Q);
  sum.push_back(Q+R);
  sum.push_back(R+P);
  sort(v.begin(), v.end(), std::greater<int>() );
  cout << v.begin() << endl;
  return 0;
}
提出情報

Compiler output:
a.cc: In function 'int main()':
a.cc:14:8: error: 'v' was not declared in this scope
   14 |   sort(v.begin(), v.end(), std::greater<int>() );
      |        ^
a.cc: At global scope:
a.cc:21:5: error: redefinition of 'int main()'
   21 | int main(){
      |     ^~~~
a.cc:5:5: note: 'int main()' previously defined here
    5 | int main(){
      |     ^~~~
a.cc: In function 'int main()':
a.cc:30:8: error: 'v' was not declared in this scope
   30 |   sort(v.begin(), v.end(), std::greater<int>() );
      |        ^
a.cc: At global scope:
a.cc:34:1: error: '\U000063d0\U000051fa\U000060c5\U00005831' does not name a type
   34 | 提出情報
      | ^~~~~~~~
Language: C++

#include<bits/stdc+.h>

using namespace std;

int main()
{
  int p,q,r;
  cin >> p >> q >> r;
  vector<int> ans(6);
  ans.at(0)=p+q;
  ans.at(1)=r+q;
  ans.at(2)=p+r;
  ans.at(3)=q+r;
  ans.at(4)=r+p;
  ans.at(5)=q+p;

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

  cout << ans.at(0) << endl;
  
  

  
  
  
}

Compiler output:
a.cc:1:9: 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 p, q, r, x;
  cin >> p >> q >> r;
  x = max(p, q, r);
  cout << p + q + r - x <<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:7:10:   required from here
    7 |   x = max(p, q, r);
      |       ~~~^~~~~~~~~
/usr/include/c++/14/bits/stl_algobase.h:306:17: error: '__comp' cannot be used as a function
  306 |       if (__comp(__a, __b))
      |           ~~~~~~^~~~~~~~~~