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


public class Main{
	public static void main(String[] args) {
        Scanner sc=new Scanner(System.in);
        int a[][]=new int[3][3];
        boolean b[][]=new boolean[3][3];
        
        for(int i=0;i<3;i++) {
        	for(int j=0;j<3;j++) {
        		a[i][j]=sc.nextInt();
        	}
        }
        int n=sc.nextInt();	
        for(int k=0;k<n;k++) {
        	int x=sc.nextInt();
        	for(int i=0;i<3;i++) {
        		for(int j=0;j<3;j++) {
        			if(x==a[i][j]) {
        				b[i][j]=true;
        			}
        		}
        	}
        		
        }
        
       boolean y=false;
       if(y==false) {
    	   if((b[0][0]==true&&b[1][1]==true&&b[2][2]==true)
    			   ||(b[0][2]==true&&b[1][1]==true&&b[2][0]==true)) {
    		  y=true; 
    	   }
       }else {
         for(int i=0;i<3;i++) {
        	if(b[0][i]==true&b[1][i]==true&b[2][i]==true) {
        		y=true;
        		break;
        	}
        
         }
         for(int j=0;j<3;j++) {
            if(b[j][0]==true&b[j][1]==true&b[j][2]==true) {
            	y=true;
            	break;
            }
            
         }
       }
       
       if(y==true) {
    	   System.out.print("Yes");
       }else {
    	   System.out.print("No");
       }
	}

}


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

#include <iostream>
#include <cstdlib>
#include <string>
#include <vector>
#include <map>
#include <algorithm>
#include <functional>
#include <iomanip>
#include <queue>
#include <stack>
#include <stdlib.h>
using namespace std;
#define rep(i,n) for (int (i) = 0; (i) <(n); (i)++) 
#include <math.h>
#include <bits/stdc++.h>
using namespace std;
int binary(int bina){
    int ans = 0;
    for (int i = 0; bina>0 ; i++)
    {
        ans = ans+(bina%2)*pow(10,i);
        bina = bina/2;
    }
    return ans;
}
long comb(int n, int r) {
    long ans = 1;
    for (int i = n; i > n - r; --i) {
        ans = ans*i;
    }
    for (int i = 1 ; i < r + 1; ++i) {
        ans = ans / i;
    }
    return ans;
}
using namespace std;
/*int main(){
    int n;std::cin >> n;
    int keta=0;
    while(true){
        keta++;
        if(n/10==0)break;
        n=n/10;
    }
    keta=keta-1;
    if(n>=7)n=3;
    else if(n>=5)n=2;
    else if(n>=3)n=1;
    int k=0;
    for(int i=3;i<=keta;i++){
        k+=comb(i-1,2);
        std::cout << k << std::endl;
    }std::cout << k << std::endl;
    k+=n*(keta);
    
    std::cout << k << std::endl;
    
}


*/
int main(){
  
                std::cout << 0 << std::endl;
              






Compiler output:
a.cc: In function 'int main()':
a.cc:64:45: error: expected '}' at end of input
   64 |                 std::cout << 0 << std::endl;
      |                                             ^
a.cc:62:11: note: to match this '{'
   62 | int main(){
      |           ^
Language: C++

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

int main() {

	int n,m,s[6],c[6],ans[4]={0,0,0,0};
	
	cin >> n >> m;
	
	for(int i=0;i<m;i++){
		cin >> s[i] >> c[i];
	}
	//if(n==3){
	for(int i=0;i<m;i++){
		if(s[i]==1){
			if(ans[2]!=0&&ans[2]!=c[i]){
				cout << -1 << endl;
				return 0;
				}
			else if(c[i]==0){
				cout << -1 << endl;
				return 0;
				}
			else ans[2]=c[i];
		}
		else if(s[i]==2){
			if(ans[1]!=0&&ans[1]!=c[i]){
				cout << -1 << endl;
				return 0;
				}
			else ans[1]=c[i];
		}
		else if(s[i]==3){
			if(ans[0]!=0&&ans[0]!=c[i]){
				cout << -1 << endl;
				return 0;
				}
			else ans[0]=c[i];
		}
	}
	
	if(n==3&&ans[2]==0){
		cout << 100+ans[1]*10+ans[0] << endl;
		return 0;
		}
	else if(n==3){
		cout << ans[2]*100+ans[1]*10+ans[0] << endl;
		return 0;
		}
	else if(n==2&&ans[1]==0){
		cout << 10+ans[0] << endl;
		return 0;
		}
	else if(n==2){
		cout << ans[1]*10+ans[0] << endl;
		return 0;
		}
	else if(n==0&&ans[0]==0){
		cout << 1 << endl;
		return 0;
		}
	else if(n==0){
		cout << ans[0] << endl;
		return 0;
		}
	}
	
	
	
	/*else if(n==2){
	for(int i=0;i<m;i++){
		if(s[i]==1){
			if(ans[1]!=0&&ans[1]!=c[i]){
				cout << -1 << endl;
				return 0;
				}
			else if(c[i]=0){
				cout << -1 << endl;
				return 0;
				}
			else ans[1]=c[i];
		}
		else if(s[i]==2){
			if(ans[0]!=0&&ans[0]!=c[i]){
				cout << -1 << endl;
				return 0;
				}
			else ans[0]=c[i];
		}
	}
	
	if(n==2&&ans[1]==0){
		cout << 10+ans[0] << endl;
		return 0;
		}
	else if(n==2){
		cout << ans[1]*10+ans[0] << endl;
		return 0;
		}
	else if(n==0&&ans[0]==0){
		cout << 1 << endl;
		return 0;
		}
	else if(n==0){
		cout << ans[0] << endl;
		return 0;
		}
	}
	
	else if(n==1){
	for(int i=0;i<m;i++){
			if(ans[0]!=0&&ans[0]!=c[i]){
				cout << -1 << endl;
				return 0;
				}
			else if(c[i]=0){
				cout << -1 << endl;
				return 0;
				}
			else ans[0]=c[i];
		}
	}
	
	if(n==0&&ans[0]==0){
		cout << 1 << endl;
		return 0;
		}
	else if(n==0){
		cout << ans[0] << endl;
		return 0;
		}*/
	}
	


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

#include <stdio.h>

int main(void){
	int n;
    scanf("%d", &n);
    if(n % 2 == 0){
    	printf("%d", n / 2);
        }
    else{
    	printf("%d", (n + 1) / 2);
        }
    }
    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++

<stdio.h>

int main(void){
	int n;
    scanf("%d", &n);
    if(n % 2 == 0){
    	printf("%d", n / 2);
        }
    else{
    	printf("%d", (n + 1) / 2);
        }
    }
    return 0;
}

Compiler output:
a.cc:1:1: error: expected unqualified-id before '<' token
    1 | <stdio.h>
      | ^
a.cc:13:5: error: expected unqualified-id before 'return'
   13 |     return 0;
      |     ^~~~~~
a.cc:14:1: error: expected declaration before '}' token
   14 | }
      | ^
Language: Java

import java.util.*;

public class Main{
	public static void main(String[] args) {
        Scanner sc=new Scanner(System.in)
        int a[][]=new int[3][3];
        boolean b[][]=new boolean[3][3];
        
        for(int i=0;i<3;i++) {
        	for(int j=0;j<3;j++) {
        		a[i][j]=sc.nextInt();
        	}
        }
        int n=sc.nextInt();	
        for(int k=0;k<n;k++) {
        	int x=sc.nextInt();
        	for(int i=0;i<3;i++) {
        		for(int j=0;j<3;j++) {
        			if(x==a[i][j]) {
        				b[i][j]=true;
        			}
        		}
        	}
        		
        }
        
       boolean y=false;
       if(y==false) {
    	   if((b[0][0]==true&&b[1][1]==true&&b[2][2]==true)
    			   ||(b[0][2]==true&&b[1][1]==true&&b[2][0]==true)) {
    		  y=true; 
    	   }
       }else {
         for(int i=0;i<3;i++) {
        	if(b[0][i]&b[1][i]&b[2][i]) y=true;
        	break;
         }
   for(int j=0;j<3;j++) {
              	if(b[j][0]&b[j][1]&b[j][2]) y=true;
         }
       }
       
       if(y==true) {
    	   System.out.print("yes");
       }else {
    	   System.out.print("no");
       }
	}

}


Compiler output:
Main.java:5: error: ';' expected
        Scanner sc=new Scanner(System.in)
                                         ^
1 error
Language: C++

// ConsoleApplication95.cpp : 此文件包含 "main" 函数。程序执行将在此处开始并结束。
//

// ConsoleApplication94.cpp : 此文件包含 "main" 函数。程序执行将在此处开始并结束。
//

#include <iostream>
#include<cstring>
#include<algorithm>
#include<iomanip>
using namespace std;
long long gcd(long long a, long long b)
{
	if (b == 0)
		return a;
	return gcd(b, a % b);
}
long long exgcd(long long a, long long b, long long& x, long long& y) {
	if (b == 0) {
		x = 1, y = 0;
		return a;
	}
	long long d = exgcd(b, a % b, y, x);
	y -= a / b * x;
	return d;
}
int main()
{
	double a;
	cin >> a;
	if (a / 2 - floor(a / 2) > 0.1)
	{
		a = floor(a / 2)+1;
	}
	else
	{
		a = a / 2;
	}
	cout << fixed << setprecision(0) << a << endl;

}


Compiler output:
a.cc: In function 'int main()':
a.cc:31:21: error: 'floor' was not declared in this scope
   31 |         if (a / 2 - floor(a / 2) > 0.1)
      |                     ^~~~~
Language: C++

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

int main() {
  int N;
  cin N;
  if (N % 2 == 0 ) {
    cout << N / 2 << endl;
  }
  else {
    cout << (N + 1) / 2 << endl;
  }
    
}


Compiler output:
a.cc: In function 'int main()':
a.cc:6:6: error: expected ';' before 'N'
    6 |   cin N;
      |      ^~
      |      ;
Language: C++

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

int main() {
   int N = 0;
   cin >> N;
   if (N % 2 = 0){
     cout << N / 2 << endl;
   }
   else{
     cout << N / 2 + 1 <<endl;
   }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:10: error: lvalue required as left operand of assignment
    7 |    if (N % 2 = 0){
      |        ~~^~~
Language: C++

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

int main() {
  int N;
  cin N;

  if (N % 2 == 0 ) {
    cout << N / 2 << endl;
  }
  else {
    cout << (N + 1) / 2 << endl;
  }
    
}


Compiler output:
a.cc: In function 'int main()':
a.cc:6:6: error: expected ';' before 'N'
    6 |   cin N;
      |      ^~
      |      ;
Language: C++

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

int main() {
  int p;
  cin p;

  if (p % 2 == 0 ) {
    cout << p / 2 << endl;
  }
  else {
    cout << (p + 1) / 2 << endl;
  }
    
}


Compiler output:
a.cc: In function 'int main()':
a.cc:6:6: error: expected ';' before 'p'
    6 |   cin p;
      |      ^~
      |      ;
Language: C++

#include <iostream>
using namespace std;
int bingo[30][30];
bool bbingo[3][3] = false;
int number[100];
int main(){
    int total;
    for(int i=0;i<3;i++){
        for(int j=0;j<3;j++){
            cin >> bingo[i][j];
        }
    }
    cin >> total;
    for(int a = 0;a < total;a++){
        cin >> number[a];
    }
    for(int i=0;i<3;i++){
        for(int j=0;j<3;j++){
            for(int a = 0;a < total;a++){
                if(bingo[i][j] == number[a]){
                    bbingo[i][j] = true;
                }
            }
        }
    }
    if(1==1){
        for(int i=0;i<3;i++){
            if(bbingo[i][1]==bbingo[i][2] && bbingo[i][1]==bbingo[i][3]){
                cout << "Yes" << endl;
                return 0;
            }
        }
    }
    else if(1==1){
        for(int j=0;j<3;j++){
            if(bbingo[1][j]==bbingo[2][j] && bbingo[1][j]==bbingo[3][j]){
                cout << "Yes" << endl;
                return 0;
            }   
        }
    }
    else if (bbingo[1][1]==bbingo[2][2] && bbingo[1][1]==bbingo[3][3]){
        cout << "Yes" << endl;
        return 0;
    }
    else if(bbingo[1][3]==bbingo[2][2] && bbingo[1][3]==bbingo[3][1]){
        cout << "Yes" << endl;
        return 0;
    }
    else {
        cout << "No" << endl;
        return 0;
    }
}


Compiler output:
a.cc:4:21: error: array must be initialized with a brace-enclosed initializer
    4 | bool bbingo[3][3] = false;
      |                     ^~~~~
Language: C++

#include <iostream>

int main() {
    int n;
    std::cin >> n;
    int remain = 0;
    if (n % 2 != 0) {
        remain = 1
    } 
    std::cout << n / 2 + remain;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:8:19: error: expected ';' before '}' token
    8 |         remain = 1
      |                   ^
      |                   ;
    9 |     }
      |     ~
Language: Java

import java.util.Scanner;
public class Main{
  public static void main(String[] args){
	Scanner sc = new Scanner(System.in);
    int N = sc.nextInt();
    int M = sc.nextInt();
    int[] s = new int[M];
    int[] c = new int[M];
    for(int i=0; i<M; i++{
      s[i] = sc.nextInt();
      c[i] = sc.nextint();
    }
    int[] num = new int[N];
    for(int i=0; i<N; i++){
    	num[i] = 0;
    }
    int ans = 0;
    int numInt = 0;
    boolean isTrue = true;
    if(int i=0; i<M; i++){
      int keta = s[i] - 1; //いじる桁 0-2 配列走査するので-1
      if(num[keta] != 0 && num[keta] != c[i]){
          isTrue = false;
          break;
      } else{
        num[keta] = c[i];
      }
    }
     if(num[0] == 0) isTrue = false;
     
     if(isTrue == false) {ans == -1;}
     else{
       for(int i=0; i<N; i++){
         for(int i=N-1; i>=0; i--){
         num[i] = num[i] *10; 
         numInt += num[i]; 
      	 }
       } 
    	ans = numInt;
     }
 
    System.out.println(ans); 
  }
}


Compiler output:
Main.java:9: error: ')' expected
    for(int i=0; i<M; i++{
                         ^
Main.java:20: error: '.class' expected
    if(int i=0; i<M; i++){
           ^
Main.java:20: error: > or ',' expected
    if(int i=0; i<M; i++){
                   ^
Main.java:20: error: not a statement
    if(int i=0; i<M; i++){
                 ^
Main.java:20: error: ';' expected
    if(int i=0; i<M; i++){
                        ^
Main.java:31: error: not a statement
     if(isTrue == false) {ans == -1;}
                              ^
6 errors
Language: Java

import java.util.Scanner
class A
{
public static void main(String args[])
{
  Scanner sc=new Scanner(System.in);
  int N=sc.nextInt();
  while(N>0 && N<101)
  {
    if(N%2==0)
    {
      System.out.println(N/2);
      break;
    }
    else
    {
      System.out.println((N/2)+1);
      break;
    }
  }
}   
}

Compiler output:
Main.java:1: error: ';' expected
import java.util.Scanner
                        ^
1 error
Language: Java

import java.util.Scanner;

public class Main {
  public static void main(String[] args ) throws Exception {
    Scanner sc = new Scanner(System.in);
    int N = sc.nextInt();
    int page = N;
    page = Math.ceil(page / 2);
    System.out.print(page);
}
}

Compiler output:
Main.java:8: error: incompatible types: possible lossy conversion from double to int
    page = Math.ceil(page / 2);
                    ^
1 error
Language: C++

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

int main() {
   int N = 0
   cin >> N;
   if (N % 2 = 0){
     cout << N / 2 << endl;
   }
   else{
     cout << N / 2 + 1 <<endl;
   }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:6:4: error: expected ',' or ';' before 'cin'
    6 |    cin >> N;
      |    ^~~
a.cc:7:10: error: lvalue required as left operand of assignment
    7 |    if (N % 2 = 0){
      |        ~~^~~
Language: C++

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

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

int main(){
  int n,ans=0;
  cin >> n;
  ans=n/2+n%2
  cout << ans;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:9:14: error: expected ';' before 'cout'
    9 |   ans=n/2+n%2
      |              ^
      |              ;
   10 |   cout << ans;
      |   ~~~~
Language: Java

import java.util.*;

public class Main {
  public static void main(String[] args ) throws Exception {
    Scanner sc = new Scanner(System.in);
    int N = sc.nextInt();
    int page = 0;
	for(int i = 0;i < N;i++){
      page = i;
    }
    page = page / 2;
    System.out.print(page);
}

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

import java.util.Scanner;

class Main {
    public static void main(String[] args) {
        int arr[][] = new int[3][3];
        Scanner in = new Scanner(System.in);
        for(int j=0; j < 3; j++){
            for(int i=0; i <3; i++){
                arr[j][i] = in.nextInt();
            }
        }
        int num = in.nextInt();
        int hit[] = new int[num];
        for(int i=0; i<num; i++){
            hit[i] = in.nextInt();
        }

        for(int j=0; j < 3; j++){
            for(int i=0; i <3; i++){
                for(int k=0; k<num; k++){
                    if(arr[j][i] == hit[i]){
                        arr[j][i] = 0;
                    }
                }
            }
        }

        // 探索
        int check[][] = {
            {0, 1, 2},
            {3, 4, 5},
            {6, 7, 8},
            {0, 3, 6},
            {1, 4, 7},
            {2, 5, 8},
            {0, 4, 8},
            {2, 4, 6}
        
        };

        boolean flag = false;

        for(int j=0; j<check.length; j++){
            if(arr[check[j][0]/3][check[j][0]%3] + arr[check[j][1]/3][check[j][1]%3] + arr[check[j][2]/3][check[j][2]%3]){
                flag = true;
            }
        }
        if(flag){
            System.out.print("Yes");
        }else{
            System.out.print("No");

        }
        
    }
}

Compiler output:
Main.java:44: error: incompatible types: int cannot be converted to boolean
            if(arr[check[j][0]/3][check[j][0]%3] + arr[check[j][1]/3][check[j][1]%3] + arr[check[j][2]/3][check[j][2]%3]){
                                                                                     ^
1 error
Language: C++

#include<iostream>
using namespace std;
int main()
{
    string result;
    result = "No"
    int a[3][3];
    for (int i = 0; i < 2; i++){
      for (int j = 0; j < 2; j++){
        cin << a[i][j]
      }
    }
      cout << result;
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:18: error: expected ';' before 'int'
    6 |     result = "No"
      |                  ^
      |                  ;
    7 |     int a[3][3];
      |     ~~~           
a.cc:10:16: error: 'a' was not declared in this scope
   10 |         cin << a[i][j]
      |                ^
Language: C++

#include<iostream>
using namespace std;
int main()
{
    result = "No"
    int a[3][3];

      cout << result;
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:5: error: 'result' was not declared in this scope
    5 |     result = "No"
      |     ^~~~~~
Language: C++

#include<iostreaam>

using namespace std;

int main()
{
  int n;
  cin>>n;
  if(n%2==0) cout<<n/2;
  else cout<<n/2+1;
  return 0;
}

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

import java.math.BigDecimal;
import java.math.RoundingMode;
class Num {
	public static void main(String[] args) {
      	int N , P;
		Scanner N = new Scanner();
		
		P = N / 2;
		P = P.setScale(0, RoundingMode.HALF_UP);
		System.out.println(P.toPlainString()); //12
	}
}

Compiler output:
Main.java:6: error: cannot find symbol
		Scanner N = new Scanner();
		^
  symbol:   class Scanner
  location: class Num
Main.java:6: error: variable N is already defined in method main(String[])
		Scanner N = new Scanner();
		        ^
Main.java:6: error: cannot find symbol
		Scanner N = new Scanner();
		                ^
  symbol:   class Scanner
  location: class Num
Main.java:9: error: int cannot be dereferenced
		P = P.setScale(0, RoundingMode.HALF_UP);
		     ^
Main.java:10: error: int cannot be dereferenced
		System.out.println(P.toPlainString()); //12
		                    ^
5 errors
Language: C++

#include <iostream>
using namespace std;
int bingo[30][30];
bool bbingo[3][3];
int number[100];
int main(){
    int total;
    for(int i=0;i<=3;i++){
        for(int j=0;j<=3;j++){
            cin >> bingo[i][j];
        }
    }
    cin >> total;
    for(int a = 0;a <= total;i++){
        cin >> number[a];
    }
    for(int i=0;i<=3;i++){
        for(int j=0;j<=3;j++){
            for(int a = 0;a <= total;a++){
                if(bingo[i][j] == number[a]){
                    bbingo[i][j] = true;
                }
            }
        }
    }
    if(){
        for(int i=0;i<=3;i++){
            if(bbingo[i][1]==bbingo[i][2] && bbingo[i][1]==bbingo[i][3]){
                cout << "Yes" << endl;
                return 0;
            }
        }
    }
    else if(){
        for(int j=0;j<=3;j++){
            if(bbingo[1][j]==bbingo[2][j] && bbingo[1][j]==bbingo[3][j]){
                cout << "Yes" << endl;
                return 0;
            }   
        }
    }
    else if (bbingo[1][1]==bbingo[2][2] && bbingo[1][1]==bbingo[3][3]){
        cout << "Yes" << endl;
        return 0;
    }
    else if(bbingo[1][3]==bbingo[2][2] && bbingo[1][3]==bbingo[3][1]){
        cout << "Yes" << endl;
        return 0;
    }
    else {
        cout << "No" << endl;
        return 0;
    }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:14:30: error: 'i' was not declared in this scope
   14 |     for(int a = 0;a <= total;i++){
      |                              ^
a.cc:26:8: error: expected primary-expression before ')' token
   26 |     if(){
      |        ^
a.cc:34:13: error: expected primary-expression before ')' token
   34 |     else if(){
      |             ^
Language: Java

import java.math.BigDecimal;
import java.math.RoundingMode;
 
public static void main(String[] args) {
      	int N , P;
		BigDecimal P = new BigDecimal(N);
		
		P = N / 2;
		BigDecimal P = bd.setScale(0, RoundingMode.HALF_UP);
		System.out.println(P.toPlainString()); //12
	}

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

#include <stdio.h>
#include <time.h>
#include <stdlib.h>

int main(void){ 
    int n,a,b;
    printf("n> ");scanf("%d",&n);
    a = n/2;
    b = n/2 + 1
    if (n % 2 == 0){
       printf("%d\n",a);
    }
    else{
        printf("%d\n",b);
    }
     
    
    return 0;
} 



Compiler output:
a.cc: In function 'int main()':
a.cc:9:16: error: expected ';' before 'if'
    9 |     b = n/2 + 1
      |                ^
      |                ;
   10 |     if (n % 2 == 0){
      |     ~~          
a.cc:13:5: error: 'else' without a previous 'if'
   13 |     else{
      |     ^~~~
Language: Java

import java.math.BigDecimal;
import java.math.RoundingMode;

public class Test1 {
	public static void main(String[] args) {
      	int N , P;
		BigDecimal P = new BigDecimal(N);
		
		P = N / 2;
		BigDecimal P = bd.setScale(0, RoundingMode.HALF_UP);
		System.out.println(P.toPlainString()); //12
	}
}

Compiler output:
Main.java:4: error: class Test1 is public, should be declared in a file named Test1.java
public class Test1 {
       ^
Main.java:7: error: variable P is already defined in method main(String[])
		BigDecimal P = new BigDecimal(N);
		           ^
Main.java:9: error: incompatible types: int cannot be converted to BigDecimal
		P = N / 2;
		      ^
Main.java:10: error: variable P is already defined in method main(String[])
		BigDecimal P = bd.setScale(0, RoundingMode.HALF_UP);
		           ^
Main.java:10: error: cannot find symbol
		BigDecimal P = bd.setScale(0, RoundingMode.HALF_UP);
		               ^
  symbol:   variable bd
  location: class Test1
5 errors
Language: Java

package atCoder;

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

public class Main {

	public static void main(String[] args) {
		// TODO Auto-generated method stub\
		Scanner s = new Scanner(System.in);
		int n = s.nextInt();
		if(n>=1 && n<=100) {
		if(n%2 == 0) {
			System.out.println(n/2);
		}else {
			System.out.println(n/2 +1);
		}
		}

	}

}


Compiler output:
Main.java:4: error: ';' expected
import java.io.*
                ^
1 error
Language: C++

#include <stdio.h>
using namespace std;
int main(){
  int N;
  cin >> N;
  cout << (N-1) / 2 + 1;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:3: error: 'cin' was not declared in this scope
    5 |   cin >> N;
      |   ^~~
a.cc:2:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
    1 | #include <stdio.h>
  +++ |+#include <iostream>
    2 | using namespace std;
a.cc:6:3: error: 'cout' was not declared in this scope
    6 |   cout << (N-1) / 2 + 1;
      |   ^~~~
a.cc:6:3: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
Language: Java

import java.util.Scanner;
public class DuplexPrinting20200301 {

    public static void main(String[] args){
        Scanner scan = new Scanner(System.in);
        int N = scan.nextInt();
        if(N%2==0){
            System.out.println(N/2);
        }else{
            System.out.println(N/2 + 1);
        }
    }
}

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

package atCoder;

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

public class DuplexPrinting {

	public static void main(String[] args) {
		// TODO Auto-generated method stub\
		Scanner s = new Scanner(System.in);
		int n = s.nextInt();
		if(n>=1 && n<=100) {
		if(n%2 == 0) {
			System.out.println(n/2);
		}else {
			System.out.println(n/2 +1);
		}
		}

	}

}


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

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

int main()
{
  int N;
  cin>>N;
 if(N%2==1)
 {
  cout<<(N+1)/2 
 }
  else
  {
   cout<<N/2; 
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:16: error: expected ';' before '}' token
   10 |   cout<<(N+1)/2
      |                ^
      |                ;
   11 |  }
      |  ~
Language: Java

import java.util.Scanner;
public class DuplexPrinting{

    public static void main(String[] args){
        Scanner scan = new Scanner(System.in);
        int N = scan.nextInt();
        if(N%2==0){
            System.out.println(N/2);
        }else{
            System.out.println(N/2 + 1);
        }
    }
}

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

package atCoder;

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

public class DuplexPrinting {

	public static void main(String[] args) {
		// TODO Auto-generated method stub\
		Scanner s = new Scanner(System.in);
		int n = s.nextInt();
		if(n>=1 && n<=100) {
		if(n%2 == 0) {
			System.out.println(n/2);
		}else {
			System.out.println(n/2 +1);
		}
		}

	}

}


Compiler output:
Main.java:4: error: ';' expected
import java.io.*
                ^
1 error
Language: C++

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

int main()
{
 if(n%2==1)
 {
  cout<<(n+1)/2 
 }
  else
  {
   cout<<n/2; 
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:5: error: 'n' was not declared in this scope; did you mean 'yn'?
    6 |  if(n%2==1)
      |     ^
      |     yn
Language: C++

// --------------------<optimizations>--------------------
#pragma GCC optimize("O3")
//(UNCOMMENT WHEN HAVING LOTS OF RECURSIONS)\
#pragma comment(linker, "/stack:200000000")
//(UNCOMMENT WHEN TRYING TO BRUTEFORCE WITH A LOT OF LOOPS)\
#pragma GCC optimize("unroll-loops")

#pragma GCC optimize("Ofast")
#pragma GCC target("avx,avx2,fma")
#pragma GCC optimization ("unroll-loops")

#include<bits/stdc++.h>

using namespace std;

#define int long long
#define ll long long
#define mp make_pair
#define pb push_back
#define eb emplace_back
#define pii pair<ll,ll>
#define vpii vector<pair<ll,ll> >
#define F first
#define S second
#define ld long double
#define built __builtin_popcountll
#define mst(a,i) memset(a,i,sizeof(a))
#define all(x) x.begin(),x.end()
#define itit(it,a) for(auto it=(a).begin(); it!=(a).end(); it++)
#define rep(i,a,b) for(ll i=a; i<b; i++)
#define repr(i,a,b) for(ll i=a; i>b; i--)
#define reprr(i,a,b) for(ll i=a; i>=b; i--)
#define pi 3.14159265358979323846264338327950288419716939937510582097494459230
ll max3(ll x,ll y,ll z) {return max(max(x,y),z);}
ll min3(ll x,ll y,ll z) {return min(min(x,y),z);}
const ll N=1e5+10,M=2e5+10,M2=1e6+10,mod=1e9+7,inf=1e17+10;
const int INF=1e9+7;
void add(int& a, int b) {a+=b;if(a>=mod){a-=mod;}}

#define trace(...) cerr<<"Line:"<<__LINE__<<" "; __f(#__VA_ARGS__, __VA_ARGS__)
template<typename Arg1>
void __f(const char *name, Arg1 &&arg1) {
    cerr<<name<<" : "<<arg1<<endl;
}
template<typename Arg1, typename ... Args>
void __f(const char *names, Arg1 &&arg1, Args &&... args) {
    const char *comma=strchr(names+1,',');
    cerr.write(names,comma-names)<<" : "<<arg1<<" | ";
    __f(comma+1,args...);
}

int X[] = {0, 1, 0, -1};
int Y[] = {-1, 0, 1, 0};
//assic value of ('0'-'9') is(48 - 57) and (a-z) is (97-122) and (A-Z) is(65-90) and 32 for space
ll power(ll x,ll n){ll result=1;while(n>0){if(n%2==1)result=(result*x)%mod; x=((x%mod)*(x%mod))%mod;n=n/2;}return result;}


int32_t main()
{
    ios::sync_with_stdio(0);
    cin.tie(0);
    cout.tie(0);
    cin >> n;
    cout << (n+1)/2;
    return 0;
}

Compiler output:
a.cc: In function 'int32_t main()':
a.cc:63:12: error: 'n' was not declared in this scope
   63 |     cin >> n;
      |            ^
Language: Java

import java.util.Scanner;
public class DuplexPrinting20200301 {
    //int N=0;
    int anser;

    public static void main(String[] args){
        Scanner scan = new Scanner(System.in);
        int N = scan.nextInt();
        if(N%2==0){
            System.out.println(N/2);
        }else{
            System.out.println(N/2 + 1);
        }
    }
}

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

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

int main()
{
  int N;
  cin>>N;
  if(n%2!=0)
  {
   cout<<n/2+1; 
  }
  else
  {
   cout<<n/2; 
  }
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:6: error: 'n' was not declared in this scope
    8 |   if(n%2!=0)
      |      ^
Language: Java

package atCoder;

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

public class DuplexPrinting {

	public static void main(String[] args) {
		// TODO Auto-generated method stub\
		Scanner s = new Scanner(System.in);
		int n = s.nextInt();
		if(n%2 == 0) {
			System.out.println(n/2);
		}else {
			System.out.println(n/2 +1);
		}

	}

}


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

#imclude<iostream>
using namespace std;
int main(){
	int num,n;
	cin>>num;
	n=num/2;
	if(n%2==0){
		cout<<n;
	}
	else{
		cout<<(n+1);
	}
	return 0;
}

Compiler output:
a.cc:1:2: error: invalid preprocessing directive #imclude; did you mean #include?
    1 | #imclude<iostream>
      |  ^~~~~~~
      |  include
a.cc: In function 'int main()':
a.cc:5:9: error: 'cin' was not declared in this scope
    5 |         cin>>num;
      |         ^~~
a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
  +++ |+#include <iostream>
    1 | #imclude<iostream>
a.cc:8:17: error: 'cout' was not declared in this scope
    8 |                 cout<<n;
      |                 ^~~~
a.cc:8:17: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:11:17: error: 'cout' was not declared in this scope
   11 |                 cout<<(n+1);
      |                 ^~~~
a.cc:11:17: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
Language: Java

import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        String line = in.nextLine();
        int value = Integer.valueOf(line);
        System.out.print("%d", (value + 1) / 2);
    }
}


Compiler output:
Main.java:8: error: no suitable method found for print(String,int)
        System.out.print("%d", (value + 1) / 2);
                  ^
    method PrintStream.print(boolean) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.print(char) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.print(int) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.print(long) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.print(float) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.print(double) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.print(char[]) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.print(String) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.print(Object) is not applicable
      (actual and formal argument lists differ in length)
1 error
Language: Java

package com.company;


public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		double num = sc.nextDouble();
		double ans;
		ans=Math.ceil(num/2);
		int a;
		a=(int)ans;
		System.out.println(a);
		}
	}


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

import java.util.Scanner;

//Distinct or Not
public class Main {
	public static void main(String[] args){

		Scanner sc = new Scanner(System.in);

		int[][] bingo = new int[3][3];
		for(int i = 0; i < 3; i++) {
			for(int j = 0; j < 3; j++) {
				bingo[i][j] = sc.nextInt();

			}
		}

		while(sc.hasNext()) {
			int num = sc.nextInt();
			for(int i = 0; i < 3; i++) {
				for(int j = 0; j < 3; j++) {
					if(bingo[i][j] == num) {
						bingo[i][j] = 0;
					}
				}
			}
		}


		//正解チェック
		int cnt = 0;
		boolean flg = false;
		//縦横チェック
		for(int i = 0; i < 3; i++) {
			for(int j = 0; j < 3; j++) {
				if(bingo[i][j] == 0) {
					cnt++;
				}
				if(cnt == 2) {
					flg = true;
				}
			}
			cnt = 0;
		}

		if(!flg) {
			//斜めチェック
			if(bingo[0][0] == 0) cnt++;
			if(bingo[1][1] == 0) cnt++;
			if(bingo[2][2] == 0) cnt++;

			if(cnt == 2) flg = true;
			cnt = 0;

			if(bingo[0][2] == 0) cnt++;
			if(bingo[1][1] == 0) cnt++;
			if(bingo[2][0] == 0) cnt++;

			if(cnt == 2) flg = true
		}

		if(flg) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

    }
}

Compiler output:
Main.java:58: error: ';' expected
			if(cnt == 2) flg = true
			                       ^
1 error
Language: Java

import java.util.Scanner;
public class DuplexPrinting20200301 {
    private int N;
    private int anser;

    public static void main(String[] args){
        Scanner scan = new Scanner(System.in);
        N=scan.nextInt();
        if(N%2==0){
            System.out.println(N/2);
        }else{
            System.out.println(N/2 + 1);
        }
    }
}

Compiler output:
Main.java:2: error: class DuplexPrinting20200301 is public, should be declared in a file named DuplexPrinting20200301.java
public class DuplexPrinting20200301 {
       ^
Main.java:8: error: non-static variable N cannot be referenced from a static context
        N=scan.nextInt();
        ^
Main.java:9: error: non-static variable N cannot be referenced from a static context
        if(N%2==0){
           ^
Main.java:10: error: non-static variable N cannot be referenced from a static context
            System.out.println(N/2);
                               ^
Main.java:12: error: non-static variable N cannot be referenced from a static context
            System.out.println(N/2 + 1);
                               ^
5 errors
Language: Java


		Scanner s = new Scanner(System.in);
		int n = s.nextInt();
		if(n%2 == 0) {
			System.out.println(n/2);
		}else {
			System.out.println(n/2 +1);
		}



Compiler output:
Main.java:2: error: unnamed classes are a preview feature and are disabled by default.
		Scanner s = new Scanner(System.in);
		^
  (use --enable-preview to enable unnamed classes)
Main.java:4: error: class, interface, enum, or record expected
		if(n%2 == 0) {
		^
Main.java:6: error: class, interface, enum, or record expected
		}else {
		^
Main.java:8: error: class, interface, enum, or record expected
		}
		^
4 errors
Language: Java

import java.util.Scanner;

class Main {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        String line = in.nextLine();
        int value = Integer.valueOf(line);
        System.out.print("%d", (value + 1) / 2);
    }
}


Compiler output:
Main.java:8: error: no suitable method found for print(String,int)
        System.out.print("%d", (value + 1) / 2);
                  ^
    method PrintStream.print(boolean) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.print(char) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.print(int) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.print(long) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.print(float) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.print(double) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.print(char[]) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.print(String) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.print(Object) is not applicable
      (actual and formal argument lists differ in length)
1 error
Language: Java

import java.util.Scanner;
public class 20200301DuplexPrinting {
    private int N;
    private int anser;

    public static void main(String[] args){
        Scanner scan = new Scanner(System.in);
        N=scan.nextInt();
        if(N%2==0){
            System.out.println(N/2);
        }else{
            System.out.println(N/2 + 1);
        }
    }
}

Compiler output:
Main.java:2: error: <identifier> expected
public class 20200301DuplexPrinting {
            ^
1 error
Language: Java

import java.util.Scanner;

public class a{
	public static void main(String args[]){
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		if(N%2==0){
			System.out.println(N/2);
		}else{
			System.out.println(N/2+1);
		}
	}
}


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

package atCoder;

import java.util.Scanner;

public class DuplexPrinting {

	public static void main(String[] args) {
		// TODO Auto-generated method stub\
		Scanner s = new Scanner(System.in);
		int n = s.nextInt();
		if(n%2 == 0) {
			System.out.println(n/2);
		}else {
			System.out.println(n/2 +1);
		}

	}

}


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

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		double num = sc.nextDouble();
		double ans;
		ans=Math.ceil(num/2);
		int a;
		a=(int)ans;
		System.out.println(a);
		}

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

import java.util.Scanner;

public class Main{
	public static void main(String args[]){
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		if(N%2==0){
			System.out.println(N/2);
		}else{
			System.out.println(N/2+1);
		}
	}
}


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:3:1: error: expected unqualified-id before 'public'
    3 | public class Main{
      | ^~~~~~
Language: C++

import java.util.Scanner;

public class a{
	public static void main(String args[]){
		Scanner sc = new Scanner(System.in);
		int N = sc.nextInt();
		if(N%2==0){
			System.out.println(N/2);
		}else{
			System.out.println(N/2+1);
		}
	}
}


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:3:1: error: expected unqualified-id before 'public'
    3 | public class a{
      | ^~~~~~
Language: C++

#include<iostream>
using namespace std;
int main()
{
    int a;
    cin >> a;
    if(a%2 == 0){
      cout << (a/2);
    }
    else (a%2 == 1){
      cout << (a/2+1);
    }
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:10:20: error: expected ';' before '{' token
   10 |     else (a%2 == 1){
      |                    ^
      |                    ;
Language: Java

import java.util.Scanner;

class Main {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        String line = in.nextLine();
        int value = Integer.valueOf(line);
        System.out.println("%d", (value + 1) / 2);
    }
}


Compiler output:
Main.java:8: error: no suitable method found for println(String,int)
        System.out.println("%d", (value + 1) / 2);
                  ^
    method PrintStream.println() is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.println(boolean) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.println(char) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.println(int) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.println(long) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.println(float) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.println(double) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.println(char[]) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.println(String) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.println(Object) is not applicable
      (actual and formal argument lists differ in length)
1 error
Language: Java

import java.util.Scanner;

public class DuplexPrinting {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);

		int a = sc.nextInt();

		if(a%2 == 0)
		{
			System.out.println((a/2));
		}
		else
		{
			System.out.println((a/2)+1);
		}
	}

}

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

class Main {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        String line = in.nextLine();
        int value = Integer.valueOf(line);
        System.out.println("%d", (value + 1) / 2);
    }
}


Compiler output:
Main.java:3: error: cannot find symbol
        Scanner in = new Scanner(System.in);
        ^
  symbol:   class Scanner
  location: class Main
Main.java:3: error: cannot find symbol
        Scanner in = new Scanner(System.in);
                         ^
  symbol:   class Scanner
  location: class Main
Main.java:6: error: no suitable method found for println(String,int)
        System.out.println("%d", (value + 1) / 2);
                  ^
    method PrintStream.println() is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.println(boolean) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.println(char) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.println(int) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.println(long) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.println(float) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.println(double) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.println(char[]) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.println(String) is not applicable
      (actual and formal argument lists differ in length)
    method PrintStream.println(Object) is not applicable
      (actual and formal argument lists differ in length)
3 errors
Language: Java

package atCoder;

import java.util.*;

public class DuplexPrinting {

	public static void main(String[] args) {
		// TODO Auto-generated method stub\
		Scanner s = new Scanner(System.in);
		int n = s.nextInt();
		if(n%2 == 0) {
			System.out.println(n/2);
		}else {
			System.out.println(n/2 +1);
		}

	}

}


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

import java.util.Scanner;
public class 20200301DuplexPrinting{
    private int N;
    private int anser;
    public static void main(String[] args){
        Scanner scan = new Scanner(System.in);
        N=scan.nextInt();
        if(N%2==0){
            System.out.println(N/2);
        }else{
            System.out.println(N/2 + 1);
        }
    }
}

Compiler output:
Main.java:2: error: <identifier> expected
public class 20200301DuplexPrinting{
            ^
1 error
Language: Java

import java.util.*;

public class A{
	public static void main(String[] args) {
		// TODO Auto-generated method stub
        Scanner sc=new Scanner(System.in);
        int n=sc.nextInt();

        if(n%2==0) {
        System.out.println(n/2);
        }else {
        	System.out.println(n/2+1);
        }
	}

}


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

#include<iostream>
using namespace std;
int main(){
  float n;
  cin>>n;
  cout<<ceil(n/2)<<endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:6:9: error: 'ceil' was not declared in this scope
    6 |   cout<<ceil(n/2)<<endl;
      |         ^~~~
Language: Java



	public static void main(String[] args) {
		// TODO Auto-generated method stub\
		Scanner s = new Scanner(System.in);
		int n = s.nextInt();
		if(n%2 == 0) {
			System.out.println(n/2);
		}else {
			System.out.println(n/2 +1);
		}

	}




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

Class Main {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        String line = in.nextLine();
        int value = Integer.valueOf(line);
        System.out.println("%d", (value + 1) / 2);
    }
}

Compiler output:
Main.java:1: error: class, interface, enum, or record expected
Class Main {
^
Main.java:2: error: unnamed classes are a preview feature and are disabled by default.
    public static void main(String[] args) {
                  ^
  (use --enable-preview to enable unnamed classes)
Main.java:8: error: class, interface, enum, or record expected
}
^
3 errors
Language: C++

#include <bits/stdc++.h>
#define int long long
using namespace std;
signed main()
{
	cin>>n;
	cout<<(n+1)/2<<endl;
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:14: error: 'n' was not declared in this scope; did you mean 'yn'?
    6 |         cin>>n;
      |              ^
      |              yn
Language: C

#include<stdio.h>

int main()
{
  int n;
  scanf("%d",&n);
  printf("%d",n/2+!);
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:7:20: error: expected expression before ')' token
    7 |   printf("%d",n/2+!);
      |                    ^
Language: C++

#include<iostream>
using namespace std;
int main(){
  float n;
  cin>>n;
  cout<<cell(n/2)<<endl;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:6:9: error: 'cell' was not declared in this scope
    6 |   cout<<cell(n/2)<<endl;
      |         ^~~~