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

//問題１　2704 上石彩花
imoort java.util.Scanner;
public class Main{
	
	public void solve(){
		Scanner sc=new Scanner(System.in);
		int a,b,sa;
		for(int i=0;i<7;i++){
			a=sc.nextInt();
			b=sc.nextInt();
			System.out.println(a-b);
		}
	}
	
	public static void main(String[]arges){
		Main obj=new Main();
		obj.solve();
	}

Compiler output:
Main.java:2: error: class, interface, enum, or record expected
imoort java.util.Scanner;
^
Main.java:18: error: reached end of file while parsing
	}
	 ^
2 errors
Language: Java

import java.util.Scanner;
public class kion{
   int a;
   int b;
   int sa;
	
	public void solve(){
		Scanner sc = new Scanner(System.in);
  		 for(int i=0;i<=6;i++){
            a = sc.nextInt();
            b = sc.nextInt();
			sa = a-b;
            System.out.println(sa);
        }
    }
	public static void main(String[] args){
		kion obj = new kion();
		obj.solve();
	}
}
	

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

#include<iostream>
#include<cstdio>
using namespace std;
int main(){
  int a[10];
  int n[10],k[10];
  for(int i=0;i<7;i++){
    cin>>n[i]>>k[i];
  }
  for(int i=0;i<7;i++){
    a[i]=n[i]-k[i];
  }
  for(int i=0;i<7;i++){
    cout<<a[i]<<endl;
  }
  return 0;
}

Compiler output:
Main.java:1: error: illegal character: '#'
#include<iostream>
^
Main.java:2: error: illegal character: '#'
#include<cstdio>
^
Main.java:6: error: not a statement
  int n[10],k[10];
             ^
Main.java:8: error: not a statement
    cin>>n[i]>>k[i];
             ^
Main.java:14: error: not a statement
    cout<<a[i]<<endl;
              ^
Main.java:4: error: unnamed classes are a preview feature and are disabled by default.
int main(){
^
  (use --enable-preview to enable unnamed classes)
Main.java:5: error: ']' expected
  int a[10];
        ^
Main.java:6: error: ']' expected
  int n[10],k[10];
        ^
8 errors
Language: Java

	import java.util.*;
	
	public class mon1{
		public static void main(String[] args){
			Scanner scan = new Scanner(System.in);
			int a = 0;
			int b = 0;
			int c = 0;
			for(int i=1;i<=7;i++){
				a = scan.nextInt();
				b = scan.nextInt();
				if(a >= b){
					c = a - b;
				}
				System.out.println(c);
			}
		}
	}
	

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


2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
 
import java.util.Scanner;
 
public class Main {
 
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
         
        int sum = 0;
int sum2=0;
         
        for(int i = 0; i < 7; i++){
            sum = sc.nextInt();
sum2=sc.nexInt();
        
         
        System.out.println(sum-sum2);
}
         
        sc.close();
    }
}
 

Compiler output:
Main.java:2: error: class, interface, enum, or record expected
2
^
1 error
Language: Java


import java.util.Scanner;
 
public class Main {
 
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
         
        int sum = 0;
int sum2=0;
         
        for(int i = 0; i < 7; i++){
            sum = sc.nextInt();
            sum2=sc.nexInt();
        
         
        System.out.println(sum-sum2);
}
         
        sc.close();
    }
}
 

Compiler output:
Main.java:14: error: cannot find symbol
            sum2=sc.nexInt();
                   ^
  symbol:   method nexInt()
  location: variable sc of type Scanner
1 error
Language: Java

import java.util.*;
 
public class Main{
    public static void main(String[] args){
        Scanner scan = new Scanner(System.in);
for(int i=0;i<7;i++){
int a=scan,nextInt();
int b=scan,nextInt();
a=a-b;
System.out.println(a);
}
}
}

Compiler output:
Main.java:7: error: ';' expected
int a=scan,nextInt();
                  ^
Main.java:8: error: ';' expected
int b=scan,nextInt();
                  ^
2 errors
Language: C

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

Compiler output:
main.c: In function 'main':
main.c:22:11: warning: missing terminating " character
   22 |     scanf("%d %d ,&a,&b);
      |           ^
main.c:22:11: error: missing terminating " character
   22 |     scanf("%d %d ,&a,&b);
      |           ^~~~~~~~~~~~~~~
main.c:23:10: error: expected ')' before ';' token
   23 |     c=a-b;
      |          ^
      |          )
main.c:22:10: note: to match this '('
   22 |     scanf("%d %d ,&a,&b);
      |          ^
main.c:23:6: error: passing argument 1 of 'scanf' makes pointer from integer without a cast [-Wint-conversion]
   23 |     c=a-b;
      |     ~^~~~
      |      |
      |      int
In file included from main.c:1:
/usr/include/stdio.h:428:42: note: expected 'const char *' but argument is of type 'int'
  428 | extern int scanf (const char *__restrict __format, ...) __wur;
      |                   ~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~
main.c:25:18: error: expected ';' before '}' token
   25 |         return 0;
      |                  ^
      |                  ;
   26 | }
      | ~
Language: C

#include<iostream>
#include<algorithm>

using namespace std;
int a, b;
int main(){
 for(int i = 0;i < 7;i++){
  cin >> a >> b;
  cout << abs(a - b) << endl;
 }
 return 0;
}

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

#include<stdio.h>
int main()
{
  int a,b,i,h[10]
  for(i=0;i<7;i++){
    scanf(%d%d,&a,&b)
      h[i]=a-b;
  }
  for(i=0;i<7;i++){
  printf("%d\n",h[i])
    }
  return 0;
}

Compiler output:
main.c: In function 'main':
main.c:5:3: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'for'
    5 |   for(i=0;i<7;i++){
      |   ^~~
main.c:5:18: error: expected ';' before ')' token
    5 |   for(i=0;i<7;i++){
      |                  ^
      |                  ;
main.c:5:18: error: expected statement before ')' token
main.c:6:11: error: expected expression before '%' token
    6 |     scanf(%d%d,&a,&b)
      |           ^
main.c:6:22: error: expected ';' before 'h'
    6 |     scanf(%d%d,&a,&b)
      |                      ^
      |                      ;
    7 |       h[i]=a-b;
      |       ~               
main.c:10:17: error: 'h' undeclared (first use in this function)
   10 |   printf("%d\n",h[i])
      |                 ^
main.c:10:17: note: each undeclared identifier is reported only once for each function it appears in
main.c:10:22: error: expected ';' before '}' token
   10 |   printf("%d\n",h[i])
      |                      ^
      |                      ;
   11 |     }
      |     ~
Language: C

#include <stdio.h>
int main(){
  int max1,mini1,max2,mini2,max3,mini3,max4,mini4,max5,mini5,max6,mini6,max7,mini7;
  scanf("%d%d",&max1,&mini1);
scanf("%d%d",&#include <stdio.h>
int main(){
  int max1,mini1,max2,mini2,max3,mini3,max4,mini4,max5,mini5,max6,mini6,max7,mini7;
  scanf("%d%d",&max1,&mini1);
scanf("%d%d",&max2,&mini2);
scanf("%d%d",&max3,&mini3);
scanf("%d%d",&max4,&mini4);
scanf("%d%d",&max5,&mini5);
scanf("%d%d",&max6,&mini6);
scanf("%d%d",&max7,&mini7);

 printf("%d\n",max1-mini1);
printf("%d\n",max2-mini2);
printf("%d\n",max3-mini3);
printf("%d\n",max4-mini4);
printf("%d\n",max5-mini5);
printf("%d\n",max6-mini6);
printf("%d\n",max7-mini7);

 return 0;
}max2,&mini2);
scanf("%d%d",&max3,&mini3);
scanf("%d%d",&max4,&mini4);
scanf("%d%d",&max5,&mini5);
scanf("%d%d",&max6,&mini6);
scanf("%d%d",&max7,&mini7);

 printf("%d\n",max1-mini1);
printf("%d\n",max2-mini2);
printf("%d\n",max3-mini3);
printf("%d\n",max4-mini4);
printf("%d\n",max5-mini5);
printf("%d\n",max6-mini6);
printf("%d\n",max7-mini7);

 return 0;
}

Compiler output:
main.c: In function 'main':
main.c:5:15: error: stray '#' in program
    5 | scanf("%d%d",&#include <stdio.h>
      |               ^
main.c:5:16: error: 'include' undeclared (first use in this function)
    5 | scanf("%d%d",&#include <stdio.h>
      |                ^~~~~~~
main.c:5:16: note: each undeclared identifier is reported only once for each function it appears in
main.c:5:25: error: 'stdio' undeclared (first use in this function); did you mean 'stdin'?
    5 | scanf("%d%d",&#include <stdio.h>
      |                         ^~~~~
      |                         stdin
main.c:6:1: error: expected expression before 'int'
    6 | int main(){
      | ^~~
Language: C

#include <stdio.h>

int main(void)
{
	int i, a, b;
	for (i = 0; i < 7; i++) {
		scanf_s("%d %d", &a, &b);
		printf("%d\n", a - b);
	}
	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", &a, &b);
      |                 ^~~~~~~
      |                 scanf
Language: C

#include<stdio.h>
int main(void){
     int a,b,c,i=7;
     while(i!=0){
           scanf("%d %d",&a,&b);
           c=-1*(-1*a--1*b);
           printf("%d\n",c);
     }
     return 0;
}

Compiler output:
main.c: In function 'main':
main.c:6:24: error: expected ')' before numeric constant
    6 |            c=-1*(-1*a--1*b);
      |                 ~      ^
      |                        )
Language: C

#include<stdio.h>

int main(void)
{
	int a[7], b, c, i;
	for (i = 0;i < 7;i++)
	{
		scanf_s("%d %d", &b, &c);
		a[i] = b - c;
	}
	for (i = 0;i < 7;i++)
	{
		printf("%d\n", a[i]);
	}
	return 0;
}

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

#include<stdio.h>
int main()
{
	int i,ma,mi;
	for(i=0;i<7;i++)
	{
		scanf("%d %d",&ma,&mi);
		printf("%d\n",ma-mi);
	}
	reutrn 0;
}

Compiler output:
main.c: In function 'main':
main.c:10:9: error: 'reutrn' undeclared (first use in this function)
   10 |         reutrn 0;
      |         ^~~~~~
main.c:10:9: note: each undeclared identifier is reported only once for each function it appears in
main.c:10:15: error: expected ';' before numeric constant
   10 |         reutrn 0;
      |               ^~
      |               ;
Language: C

#include <iostream>

using namespace std;

int main(){
  int i = 6;
  int max, min;
  while(i){
    i--;
    cin >> max >> min;
    cout << max - min << endl;
  }
}

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

#include<stdio.h>
int main(void){
	int i;
	int a[7], b[7];

	for (i = 0; i < 7; i++)
		scanf_s("%d%d", &a[i], &b[i]);

	int x = 0;
	for (i = 0; i < 7; i++){
		x = a[i] - b[i];
		printf("%d\n", x);
	}
}


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", &a[i], &b[i]);
      |                 ^~~~~~~
      |                 scanf
Language: C

#include <stdio.h>

int main(void)
}        
        int a = 0;
	int b = 0;

	for(i=0; i<7; i++)
	{
		scanf("%d", a);
		scanf("%d", b);

		if(a > b) {
			printf("%d", a-b);

		} else {
			printf("%d", b-a);
		}

	}
	
	return 0;
}

Compiler output:
main.c: In function 'main':
main.c:4:1: error: expected declaration specifiers before '}' token
    4 | }
      | ^
main.c:5:9: error: parameter 'a' is initialized
    5 |         int a = 0;
      |         ^~~
main.c:6:9: error: parameter 'b' is initialized
    6 |         int b = 0;
      |         ^~~
main.c:8:9: error: expected declaration specifiers before 'for'
    8 |         for(i=0; i<7; i++)
      |         ^~~
main.c:8:18: error: expected declaration specifiers before 'i'
    8 |         for(i=0; i<7; i++)
      |                  ^
main.c:8:23: error: expected declaration specifiers before 'i'
    8 |         for(i=0; i<7; i++)
      |                       ^
main.c:22:9: error: expected declaration specifiers before 'return'
   22 |         return 0;
      |         ^~~~~~
main.c:23:1: error: expected declaration specifiers before '}' token
   23 | }
      | ^
main.c:3:5: error: old-style parameter declarations in prototyped function definition
    3 | int main(void)
      |     ^~~~
main.c:24: error: expected '{' at end of input
Language: C

#include <stdio.h>
{
	int a = 0;
	int b = 0;

	for(int i=0; i<7; i++)
	{
		scanf("%d", a);
		scanf("%d", b);

		if(a > b) {
			printf("%d", a-b);

		} else {
			printf("%d", b-a);
		}

	}
	
	return 0;
}

Compiler output:
main.c:2:1: error: expected identifier or '(' before '{' token
    2 | {
      | ^
Language: C

#include "stdio.h"

int _tmain(int argc, _TCHAR* argv[])
{
	int a = 0;
	int b = 0;

	for(int i=0; i<7; i++)
	{
		scanf("%d", &a);
		scanf("%d", &b);

		if(a > b) {
			printf("%d", a-b);

		} else {
			printf("%d", b-a);
		}

	}
	
	return 0;
}

Compiler output:
main.c:3:22: error: unknown type name '_TCHAR'
    3 | int _tmain(int argc, _TCHAR* argv[])
      |                      ^~~~~~
Language: C++

#include<iostream>
using namesoace std;
int main(){
	int N = 7,a,b;
	while(N--){
		cin >>a >>b;
		cout << a-b << endl;
	}
}

Compiler output:
a.cc:2:7: error: expected nested-name-specifier before 'namesoace'
    2 | using namesoace std;
      |       ^~~~~~~~~
a.cc: In function 'int main()':
a.cc:6:17: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    6 |                 cin >>a >>b;
      |                 ^~~
      |                 std::cin
In file included from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:7:17: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    7 |                 cout << a-b << endl;
      |                 ^~~~
      |                 std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:7:32: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
    7 |                 cout << a-b << endl;
      |                                ^~~~
      |                                std::endl
In file included from /usr/include/c++/14/iostream:41:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
Language: C++

#include<cstdio>
using namespace std;
int main(){
    for(i=0;i<7;i++){
        scanf("%d %d",&a,&b);
        printf("%d",a-b);
    }
    return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:4:9: error: 'i' was not declared in this scope
    4 |     for(i=0;i<7;i++){
      |         ^
a.cc:5:24: error: 'a' was not declared in this scope
    5 |         scanf("%d %d",&a,&b);
      |                        ^
a.cc:5:27: error: 'b' was not declared in this scope
    5 |         scanf("%d %d",&a,&b);
      |                           ^
Language: C++

public class Main {
	Scanner sc = new Scanner(System.in);
	
	int[] dai = new int[8];
	int[] tei = new int[8];
	int[] sa = new int[8];
	int nikka ;
	int ww ;
	
	
public void syukei(){
	for (nikka=1;nikka <8;nikka++){
		System.out.println(nikka + "日目の最大気温を入力してください。；");
		 dai[nikka] = sc.nextInt();
		 System.out.println(nikka + "日目の最低気温を入力してください。；");
		 tei[nikka] = sc.nextInt();
		 sa[nikka] = dai[nikka] - tei [nikka];
		
	}
	
}
public void hyouji(){
	for(ww=1;ww<8;ww++){
		
	
	System.out.println(sa[ww]);
	}
}

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		Mondai20131 wao = new Mondai20131();
		wao.syukei();
		wao.hyouji();

Compiler output:
a.cc:1:1: error: expected unqualified-id before 'public'
    1 | public class Main {
      | ^~~~~~
Language: C++

#include<cstdio>
int main(){
	for(int a,b;scanf("%d%d",%a,%b);)printf("%d\n",a-b);
}

Compiler output:
a.cc: In function 'int main()':
a.cc:3:34: error: expected primary-expression before '%' token
    3 |         for(int a,b;scanf("%d%d",%a,%b);)printf("%d\n",a-b);
      |                                  ^
a.cc:3:37: error: expected primary-expression before '%' token
    3 |         for(int a,b;scanf("%d%d",%a,%b);)printf("%d\n",a-b);
      |                                     ^
Language: C++

#include<iostream>
#include<vector>
#include<string>
#include<cstdio>
#include<algorithm
int main(){
	for(int i=0;i<7;i++){
		int a,b;
		cin>>a>>b;
		cout<<a-b<<endl;
	}
	return 0;
}

Compiler output:
a.cc:5:19: error: missing terminating > character
    5 | #include<algorithm
      |                   ^
a.cc: In function 'int main()':
a.cc:9:17: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    9 |                 cin>>a>>b;
      |                 ^~~
      |                 std::cin
In file included from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:10:17: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   10 |                 cout<<a-b<<endl;
      |                 ^~~~
      |                 std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:10:28: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   10 |                 cout<<a-b<<endl;
      |                            ^~~~
      |                            std::endl
In file included from /usr/include/c++/14/iostream:41:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
Language: C++

#include <iostream>
#include <complex>
#include <sstream>
#include <string>
#include <algorithm>
#include <deque>
#include <list>
#include <map>
#include <numeric>
#include <queue>
#include <vector>
#include <set>
#include <limits>
#include <cstdio>
#include <cctype>
#include <cmath>
#include <cstring>
#include <cstdlib>
#include <ctime>
using namespace std;
#define REP(i, j) for(int i = 0; i < (int)(j); ++i)
#define FOR(i, j, k) for(int i = (int)(j); i < (int)(k); ++i)
#define SORT(v) sort((v).begin(), (v).end())
#define REVERSE(v) reverse((v).begin(), (v).end())
typedef complex<double> P;

int main() {
  REP(i, 7){
    int a, b; cin >>a >>b;
    cout <<a-b <<endl;
  return 0;
}

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

import java.util.Scanner;
public class Main{
    
    int a;
    int b;
    int sa;
	
    public void solve(){
        Scanner sc=new Scanner(System.in);
        	for(int i=0;i<8;i++){
				a=sc.nextInt();
				b=sc.nextInt();
				sa=a-b;
				System.out.println(sa);
        	}
	}
    
    public static void main(String[]args){
		Main obj=new Main();
        obj.solve();
    }
}

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

//2714 加藤聖弥 問1
import java.util.Scanner;
public class Main{
    int high;
    int low;
    int sa;
    int n;
    
    public void solve(){
        Scanner sc=new Scanner(System.in);
        n=0;
        while(n<7){
            high=sc.nextInt();
            low=sc.nextInt();
            sa=high-low;
            System.out.println(sa);
            n+=1;
        }
    }
    
    public static void main(String[] args){
        Main obj=new Main();
        obj.solve();
    }

Compiler output:
a.cc:2:1: error: 'import' does not name a type
    2 | import java.util.Scanner;
      | ^~~~~~
a.cc:2: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++

//2714 加藤聖弥 問1
import java.util.Scanner;
public class Main{
    int high;
    int low;
    int sa;
    int n;
    
    public void solve(){
        Scanner sc=new Scanner(System.in);
        n=0;
        while(n<7){
            high=sc.nextInt();
            low=sc.nextInt();
            sa=high-low;
            System.out.println(sa);
            n+=1;
        }
    }
    
    public static void main(String[] args){
        Main obj=new Main();
        obj.solve();
    }
}

Compiler output:
a.cc:2:1: error: 'import' does not name a type
    2 | import java.util.Scanner;
      | ^~~~~~
a.cc:2: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 Main{
    int high;
    int low;
    int sa;
    int n;
    
    public void solve(){
        Scanner sc=new Scanner(System.in);
        n=0;
        while(n<7){
            high=sc.nextInt();
            low=sc.nextInt();
            sa=high-low;
            System.out.println(sa);
            n+=1;
        }
    }
    
    public static void main(String[] args){
        Main obj=new Main();
        obj.solve();
    }
}

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

#include<stdio.h>
int main(void)
{
	int a,b,s;
	int x[7]
	for(i=0;i<=7,i++){
		scanf("%d %d",&a,&b);
	}
	s=a-b;
	printf("%d\n",s);
	return 0
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:9: error: expected initializer before 'for'
    6 |         for(i=0;i<=7,i++){
      |         ^~~
a.cc:6:17: error: 'i' was not declared in this scope
    6 |         for(i=0;i<=7,i++){
      |                 ^
a.cc:11:17: error: expected ';' before '}' token
   11 |         return 0
      |                 ^
      |                 ;
   12 | }
      | ~
Language: C++

#include<stdio.h>
int main(void)
{
	int a,b,s,i;
	int x[7];
	for(i=0;i<=7;i++){
		scanf("%d %d",&a,&b);
	}
	s=a-b;
	printf("%d\n",s);
	return 0
}

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

#include<stdio.h>
#include<windows.h>
#include<iostream>
#include <string>
#define loop(i,x) for(int i=0;i<x;i++)
using namespace std;
int main(){
	int a[7];
	int b[7];
	int x = 7;
	loop(i,x){
		cin >> a[i]>>b[i];
	}
	loop(i, x){
		cout << a[i] - b[i] << endl;
	}
	cout << endl;
	return 0;
}

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

#include<stdio.h>
#include<windows.h>
#include<iostream>
#include <string>
#define loop(i,x) for(int i=0;i<x;i++)
using namespace std;
int main(){
	int a[7];
	int b[7];
	int x = 7;
	for (int i = 0; i < x;i++){
		cin >> a[i]>>b[i];
	}
	for (int i = 0; i<x; i++){
		cout << a[i] - b[i] << endl;
	}
	cout << endl;

	return 0;
}

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

#include<stdio.h>
#include<windows.h>
#include<iostream>
#include <string>
#define loop(i,x) for(int i=0;i<x;i++)
using namespace std;
int main(){
	int a[7];
	int b[7];
	int x = 7;
	for (int i = 0; i < x;i++){
		cin >> a[i]>>b[i];
	}
	for (int n = 0; n<x; n++){
		cout << a[n] - b[n] << endl;
	}
	cout << endl;

	return 0;
}

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

#include<stdio.h>
#include<windows.h>
#include<iostream>
#include <string>

using namespace std;
int main(){
	int a[7];
	int b[7];
	int x = 7;
	for (int i = 0; i < x;i++){
		cin >> a[i]>>b[i];
	}
	for (int n = 0; n<x; n++){
		cout << a[n] - b[n] << endl;
	}
	cout << endl;

	return 0;
}

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

#include <stdio.h>
int main()
{
  int a,b,cou;
  for(cou=0;cou<7;cou++){
    scanf("%d %d",&a,&b);
    printf("%d\n"a-b);
  }
  return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:12: error: unable to find string literal operator 'operator""a' with 'const char [4]', 'long unsigned int' arguments
    7 |     printf("%d\n"a-b);
      |            ^~~~~~~
Language: C++

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


}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:26: error: invalid types 'int[int]' for array subscript
    7 |                 cout << a[i] - b[i] << endl;
      |                          ^
a.cc:7:33: error: invalid types 'int[int]' for array subscript
    7 |                 cout << a[i] - b[i] << endl;
      |                                 ^
Language: C++

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


}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:27: error: 'i' was not declared in this scope
    7 |                 cout << a[i] - b[i]<< endl;
      |                           ^
Language: C++

#include<stdio.h>
int main(){
int i,a,b;
	for(i=0;i<7;i++){
	scanf("%d %d",&a,&b);
	printf("%d\n",|b-a|);
	}
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:23: error: expected primary-expression before '|' token
    6 |         printf("%d\n",|b-a|);
      |                       ^
a.cc:6:28: error: expected primary-expression before ')' token
    6 |         printf("%d\n",|b-a|);
      |                            ^
Language: C++

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

Compiler output:
a.cc: In function 'int main()':
a.cc:8:9: error: expected '}' before 'else'
    8 |         else{
      |         ^~~~
a.cc:6:16: note: to match this '{'
    6 |         if(b>a){
      |                ^
a.cc: At global scope:
a.cc:14:9: error: expected unqualified-id before 'return'
   14 |         return 0;
      |         ^~~~~~
a.cc:15:1: error: expected declaration before '}' token
   15 | }
      | ^
Language: C++

#include<stdio.h>
int main(void){
     int a,b,c,i=7;
     while(i!=0){
           scanf("%d %d",&a,&b);
           c=-1*(-1*a--1*b);
           printf("%d\n",c);
     }
     return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:24: error: expected ')' before numeric constant
    6 |            c=-1*(-1*a--1*b);
      |                 ~      ^
      |                        )
Language: C++

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

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

#include<stdio.h>
int main(void)
{
	int a[7],k[7];
	for(i=0;i!=10;i++){
	scanf("%d %d",&a[i],&k[i]);
	goukei[i]=a[i]-k[i];
	printf("%d",goukei[i]);
}
return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:13: error: 'i' was not declared in this scope
    5 |         for(i=0;i!=10;i++){
      |             ^
a.cc:7:9: error: 'goukei' was not declared in this scope
    7 |         goukei[i]=a[i]-k[i];
      |         ^~~~~~
Language: C++

#include <iostream>
#include <stdio.h>
using namespace std

int t[7][7];
int main(){
	for(int i = 0; i < 7; i++){
		scanf("%d %d", &t[i][0], &t[i][1]);
	}
	for(int i = 0; i < 7; i++){
		printf("%d\n", t[i][0] - t[i][1]);
	}
	return 0;
}

Compiler output:
a.cc:3:20: error: expected ';' before 'int'
    3 | using namespace std
      |                    ^
      |                    ;
    4 | 
    5 | int t[7][7];
      | ~~~
Language: C++

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

int main(){
    int a,b,c,d,e,f,g,h,i,j,k,l,m,n;
    
cin >> a>>b>>c>>d>>e>>f>>g>>h>>i>>j>>k>>l>>m>>n;
    
    a =a-b;
    c=c-d;
    e=e-f;
    g=g-h;
    i=i-j;
    k=k-l;
    m =m-n;
    cout <<a<<endl;
    cout <<c<<endl;
    cout <<e<<endl;
    cout <<g<<endl;
    cout <<i<<endl;
    cout <<k<<endl;
    cout <<m<<endl;
}
    
    
    
    
    
}


Compiler output:
a.cc:2:7: error: expected nested-name-specifier before 'namesapce'
    2 | using namesapce std;
      |       ^~~~~~~~~
a.cc: In function 'int main()':
a.cc:7:1: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    7 | cin >> a>>b>>c>>d>>e>>f>>g>>h>>i>>j>>k>>l>>m>>n;
      | ^~~
      | std::cin
In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:146,
                 from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:16:5: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   16 |     cout <<a<<endl;
      |     ^~~~
      |     std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:16:15: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   16 |     cout <<a<<endl;
      |               ^~~~
      |               std::endl
In file included from /usr/include/c++/14/istream:41,
                 from /usr/include/c++/14/sstream:40,
                 from /usr/include/c++/14/complex:45,
                 from /usr/include/c++/14/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:127:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
a.cc: At global scope:
a.cc:29:1: error: expected declaration before '}' token
   29 | }
      | ^
Language: C++

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

int main(){
    int a[14];
    int o,p,q,r,s,t,u;
    
    for(int i=0;i<14;i++){
        cin >>a[i];
    }
    o=a[0]-a[1];
    p=a[2]-a[3];
    q=a[4]-a[5];
    r=a[6]-a[7];
    s=a[8]-a[9];
    t=a[10]-a[11];
    u=a[12]-a[13];
    cout <<o<endl;
    cout <<p<endl;
    cout <<q<endl;
    cout <<r<endl;
    cout <<s<endl;
    cout <<t<endl;
    cout <<u<<endl;
}
    
    
    
    
    
}


Compiler output:
a.cc:2:7: error: expected nested-name-specifier before 'namesapce'
    2 | using namesapce std;
      |       ^~~~~~~~~
a.cc: In function 'int main()':
a.cc:9:9: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    9 |         cin >>a[i];
      |         ^~~
      |         std::cin
In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:146,
                 from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:18:5: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   18 |     cout <<o<endl;
      |     ^~~~
      |     std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:18:14: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   18 |     cout <<o<endl;
      |              ^~~~
      |              std::endl
In file included from /usr/include/c++/14/istream:41,
                 from /usr/include/c++/14/sstream:40,
                 from /usr/include/c++/14/complex:45,
                 from /usr/include/c++/14/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:127:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
a.cc: At global scope:
a.cc:31:1: error: expected declaration before '}' token
   31 | }
      | ^
Language: C++

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

int main(){
    int a[14];
    int o,p,q,r,s,t,u;
    
    for(int i=0;i<14;i++){
        cin >>a[i];
    }
    o=a[0]-a[1];
    p=a[2]-a[3];
    q=a[4]-a[5];
    r=a[6]-a[7];
    s=a[8]-a[9];
    t=a[10]-a[11];
    u=a[12]-a[13];
    cout <<o<endl;
    cout <<p<endl;
    cout <<q<endl;
    cout <<r<endl;
    cout <<s<endl;
    cout <<t<endl;
    cout <<u<<endl;
}
    
    
    
    
    



Compiler output:
a.cc:2:7: error: expected nested-name-specifier before 'namesapce'
    2 | using namesapce std;
      |       ^~~~~~~~~
a.cc: In function 'int main()':
a.cc:9:9: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    9 |         cin >>a[i];
      |         ^~~
      |         std::cin
In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:146,
                 from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:18:5: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   18 |     cout <<o<endl;
      |     ^~~~
      |     std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:18:14: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   18 |     cout <<o<endl;
      |              ^~~~
      |              std::endl
In file included from /usr/include/c++/14/istream:41,
                 from /usr/include/c++/14/sstream:40,
                 from /usr/include/c++/14/complex:45,
                 from /usr/include/c++/14/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:127:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
Language: C++

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

int main(){
    int a[14];
    int o,p,q,r,s,t,u;
    
    for(int i=0;i<14;i++){
        cin >>a[i];
    }
    o=a[0]-a[1];
    p=a[2]-a[3];
    q=a[4]-a[5];
    r=a[6]-a[7];
    s=a[8]-a[9];
    t=a[10]-a[11];
    u=a[12]-a[13];
    cout <<o<endl;
    cout <<p<endl;
    cout <<q<endl;
    cout <<r<endl;
    cout <<s<endl;
    cout <<t<endl;
    cout <<u<<endl;
}



Compiler output:
a.cc:2:7: error: expected nested-name-specifier before 'namesapce'
    2 | using namesapce std;
      |       ^~~~~~~~~
a.cc: In function 'int main()':
a.cc:9:9: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    9 |         cin >>a[i];
      |         ^~~
      |         std::cin
In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:146,
                 from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:18:5: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   18 |     cout <<o<endl;
      |     ^~~~
      |     std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:18:14: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   18 |     cout <<o<endl;
      |              ^~~~
      |              std::endl
In file included from /usr/include/c++/14/istream:41,
                 from /usr/include/c++/14/sstream:40,
                 from /usr/include/c++/14/complex:45,
                 from /usr/include/c++/14/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:127:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
Language: C++

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

int main(){
    int a[14];
    int o,p,q,r,s,t,u;
    
    for(int i=0;i<14;i++){
        cin >>a[i];
    }
    o=a[0]-a[1];
    p=a[2]-a[3];
    q=a[4]-a[5];
    r=a[6]-a[7];
    s=a[8]-a[9];
    t=a[10]-a[11];
    u=a[12]-a[13];
    cout <<o<endl;
    cout <<p<endl;
    cout <<q<endl;
    cout <<r<endl;
    cout <<s<endl;
    cout <<t<endl;
    cout <<u<<endl;
}



Compiler output:
a.cc:2:7: error: expected nested-name-specifier before 'namesapce'
    2 | using namesapce std;
      |       ^~~~~~~~~
a.cc: In function 'int main()':
a.cc:9:9: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    9 |         cin >>a[i];
      |         ^~~
      |         std::cin
In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:146,
                 from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:18:5: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
   18 |     cout <<o<endl;
      |     ^~~~
      |     std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
a.cc:18:14: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
   18 |     cout <<o<endl;
      |              ^~~~
      |              std::endl
In file included from /usr/include/c++/14/istream:41,
                 from /usr/include/c++/14/sstream:40,
                 from /usr/include/c++/14/complex:45,
                 from /usr/include/c++/14/ccomplex:39,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:127:
/usr/include/c++/14/ostream:744:5: note: 'std::endl' declared here
  744 |     endl(basic_ostream<_CharT, _Traits>& __os)
      |     ^~~~
Language: C++

#include<bits.stdc++.h>
using namespace std;
int main(){
	int a,b;
	for(int i=0;i<7;i++){
		cin >> a >> b;
		cout << a-b << 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 a[14];
    int b[7];
    
    for(int i=0;i<14;i++){
        cin >>a[i];
    }
    b[0]=a[0]-a[1];
    b[1]=a[2]-a[3];
    b[2]=a[4]-a[5];
    b[3]=a[6]-a[7];
    b[4]=a[8]-a[9];
    b[5]=a[10]-a[11];
    b[6]=a[12]-a[13];
for(i=0;i<7;i++){
     cout <<b[i]<endl;   
    }
    
    
}


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

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

int main(){
   int a,b,c
   for(int i =0;i<4;i++){
      cin >> a>>b;
       if (a == 1) {
       c = 6000*b;
       cout << c<<endl;
       } else if (a == 2) {
       c = 4000*b;
       cout <<c<<endl;
       } else if (a ==3) {
       c = 3000*b;
       cout <<c<<endl; 
       } else if (a ==4) {
       c = 2000*b;
       cout <<c<<endl; 
       }
}


Compiler output:
a.cc: In function 'int main()':
a.cc:6:4: error: expected initializer before 'for'
    6 |    for(int i =0;i<4;i++){
      |    ^~~
a.cc:6:17: error: 'i' was not declared in this scope
    6 |    for(int i =0;i<4;i++){
      |                 ^
a.cc:21:2: error: expected '}' at end of input
   21 | }
      |  ^
a.cc:4:11: note: to match this '{'
    4 | int main(){
      |           ^
Language: C++

#include<stdio.h>
int main(void){
	int i;
	int a[7], b[7];

	for (i = 0; i < 7; i++)
		scanf_s("%d%d", &a[i], &b[i]);

	int x = 0;
	for (i = 0; i < 7; i++){
		x = a[i] - b[i];
		printf("%d\n", x);
	}
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:17: error: 'scanf_s' was not declared in this scope; did you mean 'scanf'?
    7 |                 scanf_s("%d%d", &a[i], &b[i]);
      |                 ^~~~~~~
      |                 scanf
Language: C++

#include<iostream>
#include<algorithm>

using namespace std;

int main(void){

int a,b'
while(cin >> a >> b){
cout << b-a << endl;
}

return 0;
}

Compiler output:
a.cc:8:8: warning: missing terminating ' character
    8 | int a,b'
      |        ^
a.cc:8:8: error: missing terminating ' character
a.cc: In function 'int main()':
a.cc:9:1: error: expected initializer before 'while'
    9 | while(cin >> a >> b){
      | ^~~~~
Language: C++

// Enjoy your stay.

#include <bits/stdc++.h>

#define EPS 1e-9
#define INF 1070000000LL
#define MOD 1000000007LL
#define fir first
#define foreach(it,X) for(auto it=(X).begin();it!=(X).end();it++)
#define ite iterator
#define mp make_pair
#define mt make_tuple
#define rep(i,n) rep2(i,0,n)
#define rep2(i,m,n) for(int i=m;i<(n);i++)
#define pb push_back
#define sec second
#define sz(x) ((int)(x).size())

using namespace std;

typedef istringstream iss;
typedef long long ll;
typedef pair<ll,ll> pi;
typedef stringstream sst;
typedef vector<ll> vi;



int main(){
	cin.tie(0);
	ios_base::sync_with_stdio(0);
	
	rep(i,7){
		int a,b;
		cin>>a>>b;
		cout<<a-b<<endl;
	}
	}
}

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

// Enjoy your stay.

#include <bits/stdc++.h>

#define EPS 1e-9
#define INF 1070000000LL
#define MOD 1000000007LL
#define fir first
//#define foreach(it,X) for(auto it=(X).begin();it!=(X).end();it++)
#define ite iterator
#define mp make_pair
#define mt make_tuple
#define rep(i,n) rep2(i,0,n)
#define rep2(i,m,n) for(int i=m;i<(n);i++)
#define pb push_back
#define sec second
#define sz(x) ((int)(x).size())

using namespace std;

typedef istringstream iss;
typedef long long ll;
typedef pair<ll,ll> pi;
typedef stringstream sst;
typedef vector<ll> vi;



int main(){
	cin.tie(0);
	ios_base::sync_with_stdio(0);
	
	rep(i,7){
		int a,b;
		cin>>a>>b;
		cout<<a-b<<endl;
	}
	}
}

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

#include <iostream>
   2:
   3:using namespace std;
   4:
   5:int main()
   6:{
   7:    int a,	b;
   8:
   9:	 while (cin >> a >> b) {
  10:        cout << a - b << endl;
  11:	 }
  12:
  13:    return 0;
  14:}

Compiler output:
a.cc:2:4: error: expected unqualified-id before numeric constant
    2 |    2:
      |    ^
a.cc:4:4: error: expected unqualified-id before numeric constant
    4 |    4:
      |    ^
Language: C++

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

Compiler output:
a.cc: In function 'int main()':
a.cc:7:28: error: 'edndl' was not declared in this scope
    7 |                 cout<<a-b<<edndl;
      |                            ^~~~~
Language: Java

public class Main {
	Scanner sc =new Scanner(System.in);
	
	int kingaku;
	int[] goukei = new int[4];
	int x;

	public void syurui(){
		for(x=0;x<=3;x++){
			int syurui = sc.nextInt();
			int maisuu = sc.nextInt();
		
		
			switch(syurui){
				case 1: kingaku = 6000; break;
				case 2: kingaku = 4000; break;
				case 3: kingaku = 3000; break;
				case 4: kingaku = 2000; break;
			}
			goukei[x] = kingaku * maisuu;
		}
	}
	public void hyouji(){
		for(x=0;x<=3;x++){
			System.out.println(goukei[x]);
		}
	}


	public static void main(String[] args) {
		Main hai = new Main();
		hai.syurui();
		hai.hyouji();

	}

}

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

import java.util.Scanner;
	public class Tiket{
		Scanner sc = new Scanner(System.in);
		int nban,nsyu;
		public void handan(){
			for(int i = 0; i<4; i++){
				nsyu = sc.nextInt();
				nban = sc.nextInt();
				switch (nsyu){
				case 1: System.out.println(nban*6000);break;
				case 2: System.out.println(nban*4000);break;
				case 3: System.out.println(nban*3000);break;
				case 4: System.out.println(nban*2000);break;
				}
			}


		}

		/**
		 * @param args
		 */
		public static void main(String[] args) {
			Tiket t = new Tiket();
			t.handan();

		}

	}

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


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


int k;
int []intake = new int[4];
int inatai;
int []atai={3,1,4,2};
int []maisu={10,4,1,5};


for(k=0;k<=4;k++){
switch(atai[k]){

case 1:inatai = 6000*maisu[k];break;
case 2:inatai = 4000*maisu[k];break;
case 3:inatai = 3000*maisu[k];break;
case 4:inatai = 2000*maisu[k];break;

inatai = intake[k];                    

System.out.println(atai[k]); 	
System.out.println(maisu[k]);
System.out.println(intake[k]);
}	
}
}
}

Compiler output:
Main.java:21: error: unreachable statement
inatai = intake[k];                    
^
1 error
Language: Java

package ;

import java.util.Scanner;

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

		public void nyuryoku(){

			int t;
			int n;
			int x;
			int ha[] = new int[4];{
			for(x=1;x>4;x++){
				t = sc.nextInt();
				n = sc.nextInt();
				switch(t) {
					case 1:
						System.out.println(6000 * n);break;
					case 2:
						System.out.println(4000 * n);break;
					case 3:
						System.out.println(3000 * n);break;
					case 4:
						System.out.println(2000 * n);break;
				}
			}
		}

		}
	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		Main2 ha = new Main2();
		ha.nyuryoku();
	}
}

Compiler output:
Main.java:1: error: <identifier> expected
package ;
       ^
1 error
Language: Java

import java.util.Scanner;

public class Main {
	Scanner sc = new Scanner(System.in);
	
	int kingaku;
	int[] goukei = new int[4];
	int n;
	
	public void syurui(){
		
		for(n=0;n<=3;n++){
		int syurui = sc.nextInt();
		int maisuu = sc.nextInt();
		
			switch (syurui){
				case 1: kingaku = 6000;break;
				case 2: kingaku = 4000;break;
				case 3: kingaku = 3000;break;
				case 4: kingaku = 2000;break;
			}	
			
		goukei[n] = kingaku * maisuu;
		}
	}
	
	public void hyouji(){
		for(n=0;n<=3;n++){
			System.out.println(goukei[n]);
		}
		
	}
	
	public static void main(String[] args) {
       Main Main = new Main();
       Main.syurui();
       Main.hyouji();
       
       
   }

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


import java.util.Scanner;
public class Main {
public static void main(String[] args) {
Scanner sc = new Scanner(System.in);

int k;
int []intake = new int[4];
int inatai;
int atai=sc.nextInt();
int maisu=sc.nextInt();


for(k=0;k<=4;k++){
switch(atai){

case 1:inatai = 6000*maisu;break;
case 2:inatai = 4000*maisu;break;
case 3:inatai = 3000*maisu;break;
case 4:inatai = 2000*maisu;break;


System.out.println(atai); 	
System.out.println(maisu);
System.out.println(inatai);
}	
}
}
}

Compiler output:
Main.java:23: error: unreachable statement
System.out.println(atai); 	
^
1 error