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

main(){int H,W,h,w;std::cin>>H>>W>>h>>w;std::cout<<(H-h)*(W-w)<<"\n";}


Compiler output:
a.cc:1:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    1 | main(){int H,W,h,w;std::cin>>H>>W>>h>>w;std::cout<<(H-h)*(W-w)<<"\n";}
      | ^~~~
a.cc: In function 'int main()':
a.cc:1:25: error: 'cin' is not a member of 'std'
    1 | main(){int H,W,h,w;std::cin>>H>>W>>h>>w;std::cout<<(H-h)*(W-w)<<"\n";}
      |                         ^~~
a.cc:1:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
  +++ |+#include <iostream>
    1 | main(){int H,W,h,w;std::cin>>H>>W>>h>>w;std::cout<<(H-h)*(W-w)<<"\n";}
a.cc:1:46: error: 'cout' is not a member of 'std'
    1 | main(){int H,W,h,w;std::cin>>H>>W>>h>>w;std::cout<<(H-h)*(W-w)<<"\n";}
      |                                              ^~~~
a.cc:1:46: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
Language: C++

#include <bits/stdc++.h>
using namespace std;
int main() 
{
  //input
  int N, M, C;
  cin  >> N >> M >> C;
  vector <int> B(M);
  for(int i = 0; i < M; ++i)
  {
    cin  >> B[i];
  }
  vector <vector <int>> A(N, vector <int>(M));
  for(int i = 0; i < N; ++i) 
  {
    for(int j = 0; j < M; ++j)
    {
      cin  >> A[i][j];
    }
  }//computeintans = 0;
  for(int i = 0; i < N; ++i) {
    //checkwhetheri-thsourcecodesolvesthisproblem
    int sum = 0;
    for(int j = 0; j < M; ++j)
    {
      sum += A[i][j] * B[j];
    }
    if(sum + C > 0) 
    {
      ++ans;
    }
  }
  //output
  cout  << ans  << endl;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:30:9: error: 'ans' was not declared in this scope; did you mean 'abs'?
   30 |       ++ans;
      |         ^~~
      |         abs
a.cc:34:12: error: 'ans' was not declared in this scope; did you mean 'abs'?
   34 |   cout  << ans  << endl;
      |            ^~~
      |            abs
Language: C++

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

int main()
{
  int H,W,w,h;
  cin>>H>>W;
  cin>>h>>w;
  int remaining= H*W-(h*W-H*w)+h*w;
  count>>remaining;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:11:3: error: 'count' was not declared in this scope
   11 |   count>>remaining;
      |   ^~~~~
Language: C++

#include <cstdio>

using namespace std;

int main()
{
  int H,W,w,h;
  cin>>H>>W;
  cin>>h>>w;
  int remaining= H*W-(h*W-H*w)+h*w;
  cout>>remaining;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:3: error: 'cin' was not declared in this scope
    8 |   cin>>H>>W;
      |   ^~~
a.cc:2:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
    1 | #include <cstdio>
  +++ |+#include <iostream>
    2 | 
a.cc:11:3: error: 'cout' was not declared in this scope
   11 |   cout>>remaining;
      |   ^~~~
a.cc:11:3: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
Language: C++

#include <cstdio>

using namespace std;

int main()
{
  int H,W,w,h;
  cin>>H>>W;
  cin>>h>>w;
  int remaining= H*W-(h*W-H*w)+h*w;
  count>>remaining;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:8:3: error: 'cin' was not declared in this scope
    8 |   cin>>H>>W;
      |   ^~~
a.cc:2:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
    1 | #include <cstdio>
  +++ |+#include <iostream>
    2 | 
a.cc:11:3: error: 'count' was not declared in this scope
   11 |   count>>remaining;
      |   ^~~~~
Language: C++

#include <iostream>
#include <vector>

using namespace std;

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

int main(void)
{
  int H, W, h, w;
  cin >> H >> W >> h >> w;
  cout << (H - h) * (W - w) << endl;
  returnn 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:14:3: error: 'returnn' was not declared in this scope
   14 |   returnn 0;
      |   ^~~~~~~
Language: C++

main=do
    [h,w] <- map read . words <$> getLine
    [h',w'] <- map read . words <$> getLine
    print $ (h-h')*(w-w')

Compiler output:
a.cc:3:7: warning: multi-character character constant [-Wmultichar]
    3 |     [h',w'] <- map read . words <$> getLine
      |       ^~~~
a.cc:4:17: warning: multi-character literal with 6 characters exceeds 'int' size of 4 bytes
    4 |     print $ (h-h')*(w-w')
      |                 ^~~~~~~~
a.cc:1:1: error: 'main' does not name a type
    1 | main=do
      | ^~~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{
  	int h,h1,w,w1;
  	scanf("%d %d %d %d",&h,&h1,&w,&w1);
	printf((h-w)*(h1-w1));
}


Compiler output:
a.cc: In function 'int main()':
a.cc:7:21: error: invalid conversion from 'int' to 'const char*' [-fpermissive]
    7 |         printf((h-w)*(h1-w1));
      |                ~~~~~^~~~~~~~
      |                     |
      |                     int
In file included from /usr/include/c++/14/cstdio:42,
                 from /usr/include/c++/14/ext/string_conversions.h:45,
                 from /usr/include/c++/14/bits/basic_string.h:4154,
                 from /usr/include/c++/14/string:54,
                 from /usr/include/c++/14/bitset:52,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:52,
                 from a.cc:1:
/usr/include/stdio.h:363:43: note:   initializing argument 1 of 'int printf(const char*, ...)'
  363 | extern int printf (const char *__restrict __format, ...);
      |                    ~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{
  	int h,h1,w,w1;
  	scanf("%d %d %d %d",&h,&h1,&w,&w1);
	printf((h-h1)*(w-w1));
}

Compiler output:
a.cc: In function 'int main()':
a.cc:7:22: error: invalid conversion from 'int' to 'const char*' [-fpermissive]
    7 |         printf((h-h1)*(w-w1));
      |                ~~~~~~^~~~~~~
      |                      |
      |                      int
In file included from /usr/include/c++/14/cstdio:42,
                 from /usr/include/c++/14/ext/string_conversions.h:45,
                 from /usr/include/c++/14/bits/basic_string.h:4154,
                 from /usr/include/c++/14/string:54,
                 from /usr/include/c++/14/bitset:52,
                 from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:52,
                 from a.cc:1:
/usr/include/stdio.h:363:43: note:   initializing argument 1 of 'int printf(const char*, ...)'
  363 | extern int printf (const char *__restrict __format, ...);
      |                    ~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~
Language: C++

#include<iostream>
using namespace std;

int main()
{
  int n,m;
  int A[n],B[n];
  
  int sum=0;
  int ans=0;
  
  for(int i=0; i<n; i++){
    cin >> A[i] >> B[i];
  }
  while(sum<m){
    int a;
    int b=B[0];
  	for (int i=0;i<n;i++){
      if(b>B[i]){
        a=A[i];
      	b=B[i];
      }
    }
    
    c = a*b;
    sum += b;
    ans += c;
    c=0;
    
    for(int i=0;i<n;i++){
      if(B[i]==b)
        B[i] +=100000;
    }
    
    cout << ans;
  }
  return 0;
}


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

#include <iostream>
#include <vector>

int main() {
  int N;
  int M;
  int C;
  std::vector<int> s;

  std::cin >> N >> M >> C;

  int B;
  for (int k = 0; k < M; k++) {
    std::cin >> B;
    s.push_back(B);
  }

  int A;
  int count = 0;
  for (int i = 0; i < N; i++) {
    int sum = 0;
    for (int j = 0; j < M; j++) {
      std::cin >> A;
      sum = sum + A * s[j] + C;
    }
    if (tmp > 0) {
      count = count + 1;
    }
  }
  std::cout << count << std::endl;
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:26:9: error: 'tmp' was not declared in this scope; did you mean 'tm'?
   26 |     if (tmp > 0) {
      |         ^~~
      |         tm
Language: C++

#include <iostream>
#include <vector>

int main() {
  int N;
  int M;
  int C;
  std::vector<int> s;

  std::cin >> N >> M >> C;

  int B;
  for (int k = 0; k < M; k++) {
    std::cin >> B;
    s.push_back(B);
  }

  int A;
  int cunt = 0;
  for (int i = 0; i < N; i++) {
    int sum = 0;
    for (int j = 0; j < M; j++) {
      std::cin >> A;
      sum = sum + A * s[j] + C;
    }
    if (sum > 0) {
      count = count + 1;
    }
  }
  std::cout << count << std::endl;
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:27:7: error: 'count' was not declared in this scope; did you mean 'cunt'?
   27 |       count = count + 1;
      |       ^~~~~
      |       cunt
a.cc:30:16: error: 'count' was not declared in this scope; did you mean 'cunt'?
   30 |   std::cout << count << std::endl;
      |                ^~~~~
      |                cunt
Language: C++

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

int main() {
  int H, W, h, w;
  cin >> H >> W;
  cin >> h >> w;
  
  cout << (H - h)*(W - w) << endl;
}

Compiler output:
a.cc:1:1: error: 'include' does not name a type
    1 | include<bits/stdc++.h>
      | ^~~~~~~
a.cc: In function 'int main()':
a.cc:6:3: error: 'cin' was not declared in this scope
    6 |   cin >> H >> W;
      |   ^~~
a.cc:9:3: error: 'cout' was not declared in this scope
    9 |   cout << (H - h)*(W - w) << endl;
      |   ^~~~
a.cc:9:30: error: 'endl' was not declared in this scope
    9 |   cout << (H - h)*(W - w) << endl;
      |                              ^~~~
Language: C++

#include<iostream>
using namespace std;

int main()
{
  int N, M, C;
  cin >> N >> M >> C;
  
  int s=0;
  
  int B[M];
  for(int k=0; k<M; k++){
        cin >> B[k];
  }
  
  int A[M];
  while(int i=0; i<N; i++){
    int S=C;
    for(int j=1; j<M; j++){
      cin >> A[j];
      S += A[j]*B[j];
    }
    if(S>0)
      s=s+1;
  }
  cout << s;
  
  return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:17:16: error: expected ')' before ';' token
   17 |   while(int i=0; i<N; i++){
      |        ~       ^
      |                )
a.cc:17:18: error: 'i' was not declared in this scope
   17 |   while(int i=0; i<N; i++){
      |                  ^
Language: C++

#include <bits/stdc++.h>

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

Compiler output:
a.cc: In function 'int main()':
a.cc:5:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    5 |   cin>>a>>b>>c>>d;
      |   ^~~
      |   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:6:3: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    6 |   cout<<(a-c)*(b-d)<<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:6:22: error: 'endl' was not declared in this scope; did you mean 'std::endl'?
    6 |   cout<<(a-c)*(b-d)<<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<stdio.h>
#include<stdlib.h>

struct Drink{
	int A;
	int B;
};

int desc(const void *a, const void *b){
	struct Drink *A = (struct Drink *)a;
	struct Drink *B = (struct Drink *)b;
	return B->A - A->A;

}

int main(){
	int N, M, *A, *B, i, j, count = 0, sum = 0;

	struct Drink *d;

	scanf("%d%d", &N, &M);
	d = (struct Drink *)malloc(sizeof(struct Drink)*N);
	for(i = 0; i < N; i++){
		scanf("%d%d", &(d->A[i]), &(d->B[i]));
	}

	qsort(d->A, sizeof(d->A)/sizeof(int), sizeof(int), desc);
	
	for(i = 0; i < N; i++){
		for(j = 0; j < d.->B[i]; j++){
			sum += d->A[i];
			count++;
			if(count == M){ break; }
		}
		if(count == M){ break; }
	}

	printf("%d", sum);

	return 0;
}


Compiler output:
main.c: In function 'main':
main.c:24:37: error: subscripted value is neither array nor pointer nor vector
   24 |                 scanf("%d%d", &(d->A[i]), &(d->B[i]));
      |                                     ^
main.c:24:49: error: subscripted value is neither array nor pointer nor vector
   24 |                 scanf("%d%d", &(d->A[i]), &(d->B[i]));
      |                                                 ^
main.c:27:16: error: passing argument 1 of 'qsort' makes pointer from integer without a cast [-Wint-conversion]
   27 |         qsort(d->A, sizeof(d->A)/sizeof(int), sizeof(int), desc);
      |               ~^~~
      |                |
      |                int
In file included from main.c:2:
/usr/include/stdlib.h:970:26: note: expected 'void *' but argument is of type 'int'
  970 | extern void qsort (void *__base, size_t __nmemb, size_t __size,
      |                    ~~~~~~^~~~~~
main.c:30:34: error: expected identifier before '->' token
   30 |                 for(j = 0; j < d.->B[i]; j++){
      |                                  ^~
main.c:31:36: error: subscripted value is neither array nor pointer nor vector
   31 |                         sum += d->A[i];
      |                                    ^
Language: C++

/* D */

#include <iostream>
#include <algorithm>
#include <sstream>
#include <string>
#include <bitset>
using namespace std;

int main(){
	int a, b;
	cin >> a >> b;

	int x[40];

	for (int i = 0; i < 40; ++i)
	{
		x[i] = 0;
	}



	for(int k = a; k <= b; k++){
		stringstream ss;
		ss << bitset<40>(k);
		string s = ss.str();

		for(int i = 0; i < 40; i++){
			if(s[i] == '1'){
				x[i]++;
			}
		}
	}

	stringstream sum;

	for(int i = 0; i < 40; i++){
		if(x[i] % 2 == 1){
			sum << x[i];
		}else{
			sum << 0;
		}
	}

	long long p;

	string a = sum.str();

	for (int i = 0; i < 40; ++i)
	{
		if(a[i] == 1){
			p += 2 ^ (39 - i);
		}
	}

	cout << p << endl;

}

Compiler output:
a.cc: In function 'int main()':
a.cc:47:16: error: conflicting declaration 'std::string a'
   47 |         string a = sum.str();
      |                ^
a.cc:11:13: note: previous declaration as 'int a'
   11 |         int a, b;
      |             ^
a.cc:51:21: error: invalid types 'int[int]' for array subscript
   51 |                 if(a[i] == 1){
      |                     ^
Language: C

#include <stdio.h>

int main(void) {
	int a, b, c, f, i, j;
	int g = 0;
	int h = 0;
	scanf("%d", &a);
	scanf("%d", &b);
	scanf("%d", &c);
	int *d = new int[b];
	int *e = new int[b];
	for (j = 0; j <= a - 1; j++) {
		for (i = 0; i <= b - 1; i++) {
			scanf("%d", &d[i]); 
			scanf("%d", &e[i]);
			f = d[i] + e[i];
			g += f;
		}

		if (g + c > 0) {
			h++;
		}
	}
	delete[] d;
	delete[] e;
	printf("%d\n", h);
	return 0;
}

Compiler output:
main.c: In function 'main':
main.c:10:18: error: 'new' undeclared (first use in this function)
   10 |         int *d = new int[b];
      |                  ^~~
main.c:10:18: note: each undeclared identifier is reported only once for each function it appears in
main.c:10:22: error: expected ',' or ';' before 'int'
   10 |         int *d = new int[b];
      |                      ^~~
main.c:11:22: error: expected ',' or ';' before 'int'
   11 |         int *e = new int[b];
      |                      ^~~
main.c:24:9: error: 'delete' undeclared (first use in this function)
   24 |         delete[] d;
      |         ^~~~~~
main.c:24:16: error: expected expression before ']' token
   24 |         delete[] d;
      |                ^
main.c:25:16: error: expected expression before ']' token
   25 |         delete[] e;
      |                ^
Language: Java

ort java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int H = sc.nextInt();
		int W = sc.nextInt();
		int h = sc.nextInt();
		int w = sc.nextInt();
		int cnt = 0;

		int[][] a = new int[H][W];

		for (int i = 0; i < H; i++) {
			for (int j = 0; j < W; j++) {
				a[i][j] = 1;
			}
		}

		for (int i = 0; i < h; i++) {
			for (int j = 0; j < W; j++) {
				a[i][j] = 0;
			}
		}

		for (int j = 0; j < w; j++) {
			for (int i = 0; i < H; i++) {
				a[i][j] = 0;
			}
		}

		for (int i = 0; i < H; i++) {
			for (int j = 0; j < W; j++) {
				if (a[i][j] == 1) {
					cnt++;
				}
			}
		}

		System.out.println(cnt);

	}
}

Compiler output:
Main.java:1: error: class, interface, enum, or record expected
ort java.util.Scanner;
^
1 error
Language: C++

#include <cstdlib> //絶対値利用のため
#include <algorithm>
#include <vector>
using namespace std;
typedef long long ll;
#define fr(i,n) for(int i=0;i<n;i++)
#define ifr(i,n) for(int i=n-1;i>=0;i--)

//const int INF = INT_MAX / 2;




int main() {
	int H, W, h, w;
	cin >> H >> W >> h >> w;
	cout << (H - h)*(W - w) << endl;
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:16:9: error: 'cin' was not declared in this scope
   16 |         cin >> H >> W >> h >> w;
      |         ^~~
a.cc:4:1: note: 'std::cin' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
    3 | #include <vector>
  +++ |+#include <iostream>
    4 | using namespace std;
a.cc:17:9: error: 'cout' was not declared in this scope
   17 |         cout << (H - h)*(W - w) << endl;
      |         ^~~~
a.cc:17:9: note: 'std::cout' is defined in header '<iostream>'; this is probably fixable by adding '#include <iostream>'
a.cc:17:36: error: 'endl' was not declared in this scope
   17 |         cout << (H - h)*(W - w) << endl;
      |                                    ^~~~
a.cc:4:1: note: 'std::endl' is defined in header '<ostream>'; this is probably fixable by adding '#include <ostream>'
    3 | #include <vector>
  +++ |+#include <ostream>
    4 | using namespace std;
Language: C++

#include<bits.stdc++.h>

using namespace std;

int main()
{
  int a, b, c, d; cin >> a >> b >> c >> d;
  cout << abs((a-c))*abs((b-d));
  return 0;
}


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<stdio.h>

int main(void){

    int H,W,h,w,white;

    scanf("%d%d%D%d",&H,&W,&h&w);

    white = (H*W) - (h+w) +1;

    printf("%d",white);

    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:7:30: error: invalid operands to binary & (have 'int *' and 'int')
    7 |     scanf("%d%d%D%d",&H,&W,&h&w);
      |                            ~~^
      |                            |
      |                            int *
Language: Java

import java.util.Scanner;

public class Main {
  public static vois main (String[] args) {
    Scanner in = new Scanner(System.in);

    while (in.hasNext()) {
      int H = in.nextInt();
      int W = in.nextInt();
      int h = in.nextInt();
      int w = in.nextInt();

      System.out.println((H - h) * (W - w));
    }
  }
}

Compiler output:
Main.java:4: error: cannot find symbol
  public static vois main (String[] args) {
                ^
  symbol:   class vois
  location: class Main
1 error
Language: C++

#include <iostream>


int main(){
int H;
int W;
int h;
int w;
cin >> H >> W;
cin >> h >> w;
cout<< H*W-H*w-h*W+h*w;

return 0;    
}

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

#include <cstream>


int main(){
int H;
int W;
int h;
int w;
cin >> H >> W;
cin >> h >> w;
cout<< H*W-H*w-h*W+h*w;

return 0;    
}

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

int main(){
int H;
int W;
int h;
int w;
cin >> H >> W;
cin >> h >> w;
cout<< H*W-H*w-h*W+h*w;

return 0;    
}

Compiler output:
a.cc: In function 'int main()':
a.cc:6:1: error: 'cin' was not declared in this scope
    6 | cin >> H >> W;
      | ^~~
a.cc:8:1: error: 'cout' was not declared in this scope
    8 | cout<< H*W-H*w-h*W+h*w;
      | ^~~~
Language: Java

import java.util.Scanner;
import java.util.List;
import java.util.ArrayList;
import java.util.Collections;
class Main{
  public static void main(String args[]){
    Scanner scan=new Scanner(System.in);
    int n=scan.nextInt();
    int m=scan.nextInt();
    List<Integer> a=new ArrayList<>();
    List<Integer> b=new ArrayList<>();
    for(int i=0;i<n;i++){
      a.add(scan.nextInt());
      b.add(scan.nextInt());
    }
    List<Integer> cop=new ArrayList<>();
    Collections.sort(cop);
    long ans=0L;
    int i=0;
    int sum=0;
    int index;
    int x,y;
    while(sum<=m){
      i++;
      x=cop.get(i);
      index=a.indexOf(x);
      y=b.get(index);
      sum+=y;
      ans+=(long)(x*y);
    }
    ans-=(long)(x*(sum-m));
    System.out.println(ans);
  }
}


Compiler output:
Main.java:31: error: variable x might not have been initialized
    ans-=(long)(x*(sum-m));
                ^
1 error
Language: C++

h1, w1 = map(int, input().split())
h2, w2 = map(int, input().split())

print((h1 - h2) * (w1 - w2))


Compiler output:
a.cc:1:1: error: 'h1' does not name a type
    1 | h1, w1 = map(int, input().split())
      | ^~
Language: C

#incliude <stdio.h>
int main(){
int a,b,c,d;
scanf("%d%d%d%d",&a,&b,&c,&d);

printf("%d",(a*d)+(b*c)-(d*c));


return 0;
}

Compiler output:
main.c:1:2: error: invalid preprocessing directive #incliude; did you mean #include?
    1 | #incliude <stdio.h>
      |  ^~~~~~~~
      |  include
main.c: In function 'main':
main.c:4:1: error: implicit declaration of function 'scanf' [-Wimplicit-function-declaration]
    4 | scanf("%d%d%d%d",&a,&b,&c,&d);
      | ^~~~~
main.c:1:1: note: include '<stdio.h>' or provide a declaration of 'scanf'
  +++ |+#include <stdio.h>
    1 | #incliude <stdio.h>
main.c:4:1: warning: incompatible implicit declaration of built-in function 'scanf' [-Wbuiltin-declaration-mismatch]
    4 | scanf("%d%d%d%d",&a,&b,&c,&d);
      | ^~~~~
main.c:4:1: note: include '<stdio.h>' or provide a declaration of 'scanf'
main.c:6:1: error: implicit declaration of function 'printf' [-Wimplicit-function-declaration]
    6 | printf("%d",(a*d)+(b*c)-(d*c));
      | ^~~~~~
main.c:6:1: note: include '<stdio.h>' or provide a declaration of 'printf'
main.c:6:1: warning: incompatible implicit declaration of built-in function 'printf' [-Wbuiltin-declaration-mismatch]
main.c:6:1: note: include '<stdio.h>' or provide a declaration of 'printf'
Language: Java



import java.io.BufferedInputStream;
import java.io.BufferedOutputStream;
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.io.OutputStream;
import java.nio.charset.StandardCharsets;
import java.util.LinkedList;
import java.util.List;
import java.util.TreeMap;
//import org.apache.commons.lang3.StringUtils;
 
 
/**
 *
 * @author aj
 */
public class WhiteCells {
    
    public static void main(String[] args){
        try {
            //Scanner sc = new Scanner(System.in);
            BufferedInputStream bf = new BufferedInputStream(System.in);
            BufferedReader in = new BufferedReader(
                    new InputStreamReader(bf, StandardCharsets.UTF_8));
            OutputStream out = new BufferedOutputStream ( System.out );
            String[] HW = in.readLine().split(" ");
            String[] hw = in.readLine().split(" ");
            int H = Integer.parseInt(HW[0]);
            int W = Integer.parseInt(HW[1]);
            int h = Integer.parseInt(hw[0]);
            int w = Integer.parseInt(hw[1]);
            int r = H*W - ( h*(W-w) + h*w + w*(H-h));
            out.write((r+"\n").getBytes());
            out.flush();
        }catch(Exception ex){
            ex.printStackTrace();
        }
        
    }
    
    
    
}

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

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

int main() {

  int H;
  int W;
  int h;
  int w;
  
  cin >> H >> W ;
  cin >> h >> w ;
  
  cout <<(H-h)*(W-w) << endl;
}


Compiler output:
a.cc:1:1: error: 'include' does not name a type
    1 | include <bits/stdc++.h>
      | ^~~~~~~
a.cc: In function 'int main()':
a.cc:11:3: error: 'cin' was not declared in this scope
   11 |   cin >> H >> W ;
      |   ^~~
a.cc:14:3: error: 'cout' was not declared in this scope
   14 |   cout <<(H-h)*(W-w) << endl;
      |   ^~~~
a.cc:14:25: error: 'endl' was not declared in this scope
   14 |   cout <<(H-h)*(W-w) << endl;
      |                         ^~~~
Language: C

#include <stdio.h>

int main(void) {
	int a, b, c, d, e;
	scanf_s("%d %d\n", &a, &b);
	scanf_s("%d %d\n", &c, &d);
	e = a * b - (a * d + b * c - c * d);
	printf("%d\n", e);
	return 0;
}

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

#include<iostream>
using namespace std;

int main(){
  	int h,w,a,b;
  	int hoge,ans;
  	cin >> h >> w;
  	cin >> a >> b;
  	hoge=h*w;
  	ans=a*w+b*h;
  	if(a>b){
		c=a;
    }else if(b>a){
      	c=b;	
    }else{
		c=a+b;
    }
  	ans=ans-c;
  	cout << hoge-ans << '\n';
  	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:17: error: 'c' was not declared in this scope
   12 |                 c=a;
      |                 ^
a.cc:14:9: error: 'c' was not declared in this scope
   14 |         c=b;
      |         ^
a.cc:16:17: error: 'c' was not declared in this scope
   16 |                 c=a+b;
      |                 ^
a.cc:18:17: error: 'c' was not declared in this scope
   18 |         ans=ans-c;
      |                 ^
Language: C++

#include <iostream>

using namespace std;

main(){int H; int W; int h; int w;
      cin>>H;cin>>W;cin>>h;cin>>
      w;cout<<H*W-h-w+1;return 0;}#include <iostream>

using namespace std;

main(){int H; int W; int h; int w;
      cin>>H;cin>>W;cin>>h;cin>>
      w;cout<<H*W-h*W-w*H+h*w;return 0;}


Compiler output:
a.cc:7:35: error: stray '#' in program
    7 |       w;cout<<H*W-h-w+1;return 0;}#include <iostream>
      |                                   ^
a.cc:5:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    5 | main(){int H; int W; int h; int w;
      | ^~~~
a.cc:7:36: error: 'include' does not name a type
    7 |       w;cout<<H*W-h-w+1;return 0;}#include <iostream>
      |                                    ^~~~~~~
a.cc:11:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
   11 | main(){int H; int W; int h; int w;
      | ^~~~
a.cc:11:1: error: redefinition of 'int main()'
a.cc:5:1: note: 'int main()' previously defined here
    5 | main(){int H; int W; int h; int w;
      | ^~~~
Language: C

#include<stdio.h>

int main(){
    int H,W,h,w;
    int allTrout,result,ret;
    ret = scanf("%d %d",&H,&W);
    ret = scanf("%d %d",&h,&w);

    if W < 0;
    {
        return 0;
    }
    allTrout = H*W;
    result = allTrout - ((h*W+w*H) - (h*w));
    printf("%d",result);
    return result;
}

Compiler output:
main.c: In function 'main':
main.c:9:8: error: expected '(' before 'W'
    9 |     if W < 0;
      |        ^
      |        (
Language: C

include<stdio.h>

int main(void){
  int h,w,H,W;
  scanf("%d %d",&H,&W);
  scanf("%d %d",&h,&w);
  printf("%d\n",H*W-h*W-H*w+h*w);
  return 0;
}

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

# -*- coding: utf-8 -*-

A, B = list(map(int, input().split()))

a, b = list(map(int, input().split()))

print((A - a) * (B - b))

Compiler output:
a.cc:1:3: error: invalid preprocessing directive #-
    1 | # -*- coding: utf-8 -*-
      |   ^
a.cc:3:1: error: 'A' does not name a type
    3 | A, B = list(map(int, input().split()))
      | ^
Language: C++

#include <bits/stdc++.h>
#define _ ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);
#define int long long
#define pb push_back
#define sz(i) (int)(i.size())
#define F first
#define S second
#define L long double
#define P pair<int, int>
const int inf = 0x3f3f3f3f3f3f3f3LL;
const int mod = (int)1e9 + 7;
using namespace std;
#if ONLINE_JUDGE
#define tr(...)
#define endl '\n'
#else
#include "../../tr.h"
#endif
template<class T> void smin(T& a, T val) {if (a > val) a = val;}template<class T> void smax(T& a, T val) {if (a < val) a = val;}
const int N = 5*(int)1e5 + 10;

int n, a[N];

int32_t main(){_

   int H, W, h, w;
   cin>>H>>W>>h>>w;

   cout<<(H-h)*(W-w);

   #warning make sure N size is correct!
   return 0;
}

Compiler output:
a.cc:17:10: fatal error: ../../tr.h: No such file or directory
   17 | #include "../../tr.h"
      |          ^~~~~~~~~~~~
compilation terminated.
Language: C++

#include <iostream>

using namespace std;

main(){int H; int W; int h; int w;
      cin>>H;cin>>W;cin>>h;cin>>
      w;cout<<H*W-h*H-w*W+h*w;}return 0;


Compiler output:
a.cc:5:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    5 | main(){int H; int W; int h; int w;
      | ^~~~
a.cc:7:32: error: expected unqualified-id before 'return'
    7 |       w;cout<<H*W-h*H-w*W+h*w;}return 0;
      |                                ^~~~~~
Language: C++

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace ConsoleApplication1
{
    class Program
    {
        static void Main(string[] args)
        {
            string[] hw = Console.ReadLine().Split(' ');
            int H = int.Parse(hw[0]);
            int W = int.Parse(hw[1]);
            string[] hw2 = Console.ReadLine().Split(' ');
            int h2 = int.Parse(hw2[0]);
            int w2 = int.Parse(hw2[1]);
            int ans = (H - h2) * (W - w2);
            Console.WriteLine(ans);

        }
    }
}


Compiler output:
a.cc:1:7: error: expected nested-name-specifier before 'System'
    1 | using System;
      |       ^~~~~~
a.cc:2:7: error: expected nested-name-specifier before 'System'
    2 | using System.Collections.Generic;
      |       ^~~~~~
a.cc:3:7: error: expected nested-name-specifier before 'System'
    3 | using System.Linq;
      |       ^~~~~~
a.cc:4:7: error: expected nested-name-specifier before 'System'
    4 | using System.Text;
      |       ^~~~~~
a.cc:10:26: error: 'string' has not been declared
   10 |         static void Main(string[] args)
      |                          ^~~~~~
a.cc:10:35: error: expected ',' or '...' before 'args'
   10 |         static void Main(string[] args)
      |                                   ^~~~
a.cc:22:6: error: expected ';' after class definition
   22 |     }
      |      ^
      |      ;
a.cc: In static member function 'static void ConsoleApplication1::Program::Main(int*)':
a.cc:12:13: error: 'string' was not declared in this scope
   12 |             string[] hw = Console.ReadLine().Split(' ');
      |             ^~~~~~
a.cc:12:20: error: expected primary-expression before ']' token
   12 |             string[] hw = Console.ReadLine().Split(' ');
      |                    ^
a.cc:13:21: error: expected primary-expression before 'int'
   13 |             int H = int.Parse(hw[0]);
      |                     ^~~
a.cc:14:21: error: expected primary-expression before 'int'
   14 |             int W = int.Parse(hw[1]);
      |                     ^~~
a.cc:15:20: error: expected primary-expression before ']' token
   15 |             string[] hw2 = Console.ReadLine().Split(' ');
      |                    ^
a.cc:16:22: error: expected primary-expression before 'int'
   16 |             int h2 = int.Parse(hw2[0]);
      |                      ^~~
a.cc:17:22: error: expected primary-expression before 'int'
   17 |             int w2 = int.Parse(hw2[1]);
      |                      ^~~
a.cc:19:13: error: 'Console' was not declared in this scope
   19 |             Console.WriteLine(ans);
      |             ^~~~~~~
Language: C

#include <stdio.h>

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

Compiler output:
main.c: In function 'main':
main.c:5:11: error: expected expression before '%' token
    5 |     scanf(%d,%d, &a, &b);
      |           ^
main.c:6:11: error: expected expression before '%' token
    6 |     scanf(%d,%d, &c, &d);
      |           ^
Language: C

include<stdio.h>

int main(void){
  int h,w,H,W;
  scanf("%d %d",H,W);
  scanf("%d %d",h,w);
  printf("%d\n",H*W-h*W-H*w+h*w);
  return 0;
}

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

import java.util.Scanner;

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

    int     ans;

    Scanner sc = new Scanner(System.in);

    int ans;

    int H = sc.nextInt();
    int W = sc.nextInt();

    int h = sc.nextInt();
    int w = sc.nextInt();

    if (H == h && W == w) {
      System.out.println(0);
    } else {

      ans = w*h + h*(W-w);

      System.out.println(ans);
    }

  }

}


Compiler output:
Main.java:10: error: variable ans is already defined in method main(String[])
    int ans;
        ^
1 error
Language: C++

#include <iostream>
#include <vector>
#include <map>
#include <set>
#include <queue>
#include <string>
#include <iomanip>
#include <algorithm>
#include <cmath>
#include <stdio.h>
using namespace std;
#define int long long
int MOD = 1000000007;
signed main() {
	cin.tie(0);
	ios::sync_with_stdio(false);
	int H, W;
	cin >> H >> W;
	int h, w;
	cin >> h >> w;
	cout << (H - h)*(W - w) << endl
}

Compiler output:
a.cc: In function 'int main()':
a.cc:21:40: error: expected ';' before '}' token
   21 |         cout << (H - h)*(W - w) << endl
      |                                        ^
      |                                        ;
   22 | }
      | ~
Language: C

#include <stdio.h>

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

Compiler output:
main.c: In function 'main':
main.c:5:11: error: expected expression before '%' token
    5 |     scanf(%d %d, a, b);
      |           ^
main.c:6:11: error: expected expression before '%' token
    6 |     scanf(%d %d, c, d);
      |           ^
Language: Java

import java.util.Scanner;

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

    int     ans;

    Scanner sc = new Scanner(System.in);

    int ans;

    int H = sc.nextInt();
    int W = sc.nextInt();

    int h = sc.nextInt();
    int w = sc.nextInt();

    if (H = h && W = w) {
      System.out.println(0);
    } else {

      ans = w*h + h*(W-w);

      System.out.println(ans);
    }

  }

}


Compiler output:
Main.java:10: error: variable ans is already defined in method main(String[])
    int ans;
        ^
Main.java:18: error: bad operand types for binary operator '&&'
    if (H = h && W = w) {
              ^
  first type:  int
  second type: int
Main.java:18: error: incompatible types: int cannot be converted to boolean
    if (H = h && W = w) {
          ^
3 errors
Language: C++

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

int main(){
  int h,w,a,b;
  int hoge,ans;
  int c,d;
  cin >> h >> w;
  cin >> a >> b;
  hoge = h*w;
  c = a*w;
  d = b*h;
  ans = c+d-1;
  cout << hoge-ans << '\n';
  return 0;
}


Compiler output:
a.cc:1:1: error: 'include' does not name a type
    1 | include<bits/stdc++.h>
      | ^~~~~~~
a.cc: In function 'int main()':
a.cc:8:3: error: 'cin' was not declared in this scope
    8 |   cin >> h >> w;
      |   ^~~
a.cc:14:3: error: 'cout' was not declared in this scope
   14 |   cout << hoge-ans << '\n';
      |   ^~~~
Language: Java

import java.util.Scanner;

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

    int     ans;

    Scanner sc = new Scanner(System.in);

    int ans;
    
    int H = sc.nextInt();
    int W = sc.nextInt();
    
    int h = sc.nextInt();
    int w = sc.nextInt();

    if (H = h && W = w) {
      Systsm.out.println(0);
    } else {

      ans = w*h + h*(W-w);
      
      System.out.println(ans);
    }

  }

}


Compiler output:
Main.java:10: error: variable ans is already defined in method main(String[])
    int ans;
        ^
Main.java:18: error: bad operand types for binary operator '&&'
    if (H = h && W = w) {
              ^
  first type:  int
  second type: int
Main.java:18: error: incompatible types: int cannot be converted to boolean
    if (H = h && W = w) {
          ^
Main.java:19: error: package Systsm does not exist
      Systsm.out.println(0);
            ^
4 errors
Language: Java

public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ

		Scanner sc = new Scanner(System.in);
		int H = sc.nextInt();
		int W = sc.nextInt();
		int h = sc.nextInt();
		int w = sc.nextInt();
		int res = H * W;

		res -= W * h;
		res -= (H-h)*w;

		System.out.println(res);

		sc.close();
	}

}

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

#include<cstdio>
#include<algorithm>

int main(int argc, char const *argv[]){
  int largeH,largeW,h,w;
  scanf("%d %d %d %d",&largeH,largeW,h,w);
  printf(largeH*largeW-h-w+1);
}

Compiler output:
a.cc: In function 'int main(int, const char**)':
a.cc:7:27: error: invalid conversion from 'int' to 'const char*' [-fpermissive]
    7 |   printf(largeH*largeW-h-w+1);
      |          ~~~~~~~~~~~~~~~~~^~
      |                           |
      |                           int
In file included from /usr/include/c++/14/cstdio:42,
                 from a.cc:1:
/usr/include/stdio.h:363:43: note:   initializing argument 1 of 'int printf(const char*, ...)'
  363 | extern int printf (const char *__restrict __format, ...);
      |                    ~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~
Language: C++


import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		
		Scanner sc = new Scanner(System.in);
		
		int row = sc.nextInt();
		int col = sc.nextInt();
		int r = sc.nextInt();
		int w = sc.nextInt();
		
		System.out.println((row-r) * (col - w));
	}
}


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

#include<stdio.h>

int main(){
	int H,W;
  	int h,w;
	scanf("%d %d\n%d %d", &H, &W, &h, &w);
  	int block = (h * W) + (w * H) - (h * w);
  	int white = (H * W) - black;
  	printf("%d",white);
  	return 0;
}

Compiler output:
main.c: In function 'main':
main.c:8:31: error: 'black' undeclared (first use in this function); did you mean 'block'?
    8 |         int white = (H * W) - black;
      |                               ^~~~~
      |                               block
main.c:8:31: note: each undeclared identifier is reported only once for each function it appears in
Language: C

#include <stdio.h>
int main()
｛ 
int H,W,h,w,N,t,y;
scanf("%d %d",&H,&W);
scanf("%d %d",&h,&w);
N＝W*H;
t＝h*W;
y＝w*H;
printf("%d",N-t-y);
return 0;
｝

Compiler output:
main.c: In function 'main':
main.c:3:1: error: expected declaration specifiers before '\U0000ff5b'
    3 | ｛
      | ^~
main.c:5:1: error: expected declaration specifiers before 'scanf'
    5 | scanf("%d %d",&H,&W);
      | ^~~~~
main.c:6:1: error: expected declaration specifiers before 'scanf'
    6 | scanf("%d %d",&h,&w);
      | ^~~~~
main.c:7:1: error: unknown type name 'N\U0000ff1dW'
    7 | N＝W*H;
      | ^~~~
main.c:8:1: error: unknown type name 't\U0000ff1dh'
    8 | t＝h*W;
      | ^~~~
main.c:9:1: error: unknown type name 'y\U0000ff1dw'
    9 | y＝w*H;
      | ^~~~
main.c:9:6: error: redefinition of parameter 'H'
    9 | y＝w*H;
      |      ^
main.c:7:6: note: previous definition of 'H' with type 'int *'
    7 | N＝W*H;
      |      ^
main.c:10:1: error: expected declaration specifiers before 'printf'
   10 | printf("%d",N-t-y);
      | ^~~~~~
main.c:11:1: error: expected declaration specifiers before 'return'
   11 | return 0;
      | ^~~~~~
main.c:12:1: error: expected declaration specifiers before '\U0000ff5d'
   12 | ｝
      | ^~
main.c:9:6: error: declaration for parameter 'H' but no such parameter
    9 | y＝w*H;
      |      ^
main.c:8:6: error: declaration for parameter 'W' but no such parameter
    8 | t＝h*W;
      |      ^
main.c:7:6: error: declaration for parameter 'H' but no such parameter
    7 | N＝W*H;
      |      ^
Language: C++

#include <iostream>
using namespace std;

int main(){
    long long int H,W,h,w;
    

    cin>>H>>W;

    cin>>h>>w;

    sum=(H-h)*(W-w);

    cout<<sum<<endl;

    return 0;


}

Compiler output:
a.cc: In function 'int main()':
a.cc:12:5: error: 'sum' was not declared in this scope
   12 |     sum=(H-h)*(W-w);
      |     ^~~
Language: C++

#include<bits/stdc++.h>
using namespace std;
int main()
{
    
    int H;
    cin >> H;
    
    int W;
    cin >> W;
 
    int h;
     cin >> h;
    int w;
     cin >>w 
  
   cout << (H*W-h*w)  << endl;
    return 0;
}


Compiler output:
a.cc: In function 'int main()':
a.cc:15:13: error: expected ';' before 'cout'
   15 |      cin >>w
      |             ^
      |             ;
   16 | 
   17 |    cout << (H*W-h*w)  << endl;
      |    ~~~~
Language: C++

fn main() {
    let mut buf = String::new();
    std::io::stdin().read_line(&mut buf).unwrap();
    let mut iter = buf.split_whitespace();
    let h_size: u32 = iter.next().unwrap().parse().unwrap();
    let w_size: u32 = iter.next().unwrap().parse().unwrap();

    let mut buf = String::new();
    std::io::stdin().read_line(&mut buf).unwrap();
    let mut iter = buf.split_whitespace();
    let h: u32 = iter.next().unwrap().parse().unwrap();
    let w: u32 = iter.next().unwrap().parse().unwrap();

    println!("{}", h_size*w_size - h*w_size - w*(h_size-h));
}


Compiler output:
a.cc:1:1: error: 'fn' does not name a type
    1 | fn main() {
      | ^~
Language: C++

#include <iostream>

using namespace std;

main(){int H; int W; int h; int w;
      cin>>H;cin>>W;cin>>h;cin>>
      w;cout<<H*W-h-w+1;}return 0;

Compiler output:
a.cc:5:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
    5 | main(){int H; int W; int h; int w;
      | ^~~~
a.cc:7:26: error: expected unqualified-id before 'return'
    7 |       w;cout<<H*W-h-w+1;}return 0;
      |                          ^~~~~~
Language: C++

#include<bits/stdc++.h>
 2using namespace std;
 3
 4int main(){
 5  int h,w,a,b;
 6  int hoge,ans;
 7  int c,d;
 8  cin >> h >> w;
 9  cin >> a >> b;
10  hoge = h*w;
11  c = a*w;
12  d = b*h;
13  ans = c+d-1;
14  cout << hoge-ans << '\n';
15  return 0;
16}


Compiler output:
a.cc:2:2: error: expected unqualified-id before numeric constant
    2 |  2using namespace std;
      |  ^~~~~~
a.cc:3:2: error: expected unqualified-id before numeric constant
    3 |  3
      |  ^
Language: C++


fn main() {
    let mut buf = String::new();
    std::io::stdin().read_line(&mut buf).unwrap();
    let mut iter = buf.split_whitespace();
    let h_size: u32 = iter.next().unwrap().parse().unwrap();
    let w_size: u32 = iter.next().unwrap().parse().unwrap();

    let mut buf = String::new();
    std::io::stdin().read_line(&mut buf).unwrap();
    let mut iter = buf.split_whitespace();
    let h: u32 = iter.next().unwrap().parse().unwrap();
    let w: u32 = iter.next().unwrap().parse().unwrap();

    println!("{}", h_size*w_size - h*w_size - w*(h_size-h));
}


Compiler output:
a.cc:2:1: error: 'fn' does not name a type
    2 | fn main() {
      | ^~
Language: C++

#include <stdio.h>

int main() {
	int h, w, H, W;
	scanf_s("%d %d", &h, &w);
	scanf_s("%d %d", &H, &W);
	printf("%d", H*W - (h*W + w*H - h*w));
	return 0;
}

Compiler output:
a.cc: In function 'int main()':
a.cc:5:9: error: 'scanf_s' was not declared in this scope; did you mean 'scanf'?
    5 |         scanf_s("%d %d", &h, &w);
      |         ^~~~~~~
      |         scanf
Language: C++

#include<stdio.h>
int main()
｛ 
int H,W,h,w,N,t,y;
scanf("%d %d",&H,&W);
scanf("%d %d",&h,&w);
N＝W*H;
t＝h*W;
y＝w*H;
printf("%d",N-t-y);
return 0;
｝


Compiler output:
a.cc:3:1: error: expected initializer before '\U0000ff5b'
    3 | ｛
      | ^~
a.cc:5:6: error: expected constructor, destructor, or type conversion before '(' token
    5 | scanf("%d %d",&H,&W);
      |      ^
a.cc:6:6: error: expected constructor, destructor, or type conversion before '(' token
    6 | scanf("%d %d",&h,&w);
      |      ^
a.cc:7:1: error: 'N\U0000ff1dW' does not name a type
    7 | N＝W*H;
      | ^~~~
a.cc:8:1: error: 't\U0000ff1dh' does not name a type
    8 | t＝h*W;
      | ^~~~
a.cc:9:1: error: 'y\U0000ff1dw' does not name a type
    9 | y＝w*H;
      | ^~~~
a.cc:10:7: error: expected constructor, destructor, or type conversion before '(' token
   10 | printf("%d",N-t-y);
      |       ^
a.cc:11:1: error: expected unqualified-id before 'return'
   11 | return 0;
      | ^~~~~~
a.cc:12:1: error: '\U0000ff5d' does not name a type
   12 | ｝
      | ^~
Language: C++

#include <iostream>
using namespace std;
 
int main() {
  int h,w;
  int h_, w_;
  
  cin >> h >> w;
  cin >> h_ >> w_;
  
  cout << (w-w_)*(h-h_) << endl;
  
  return 0;


Compiler output:
a.cc: In function 'int main()':
a.cc:13:12: error: expected '}' at end of input
   13 |   return 0;
      |            ^
a.cc:4:12: note: to match this '{'
    4 | int main() {
      |            ^
Language: C++

#include<cstdio>
uaing namespace std;
int main()
{
	int a,b,c,d;
	scanf("%d%d%d%d",&a,&b,&c,&d);
	printf("%d",(a-c)*(b-d));
	return 0;
}

Compiler output:
a.cc:2:1: error: 'uaing' does not name a type
    2 | uaing namespace std;
      | ^~~~~
Language: C++

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

Compiler output:
a.cc:2:1: error: 'uing' does not name a type; did you mean 'uint'?
    2 | uing namespace std;
      | ^~~~
      | uint
a.cc: In function 'int main()':
a.cc:5:3: error: 'cin' was not declared in this scope; did you mean 'std::cin'?
    5 |   cin>>h>>w>>a>>b;
      |   ^~~
      |   std::cin
In file included from /usr/include/x86_64-linux-gnu/c++/14/bits/stdc++.h:146,
                 from a.cc:1:
/usr/include/c++/14/iostream:62:18: note: 'std::cin' declared here
   62 |   extern istream cin;           ///< Linked to standard input
      |                  ^~~
a.cc:6:3: error: 'cout' was not declared in this scope; did you mean 'std::cout'?
    6 |   cout<<(h-a)*(w-b);
      |   ^~~~
      |   std::cout
/usr/include/c++/14/iostream:63:18: note: 'std::cout' declared here
   63 |   extern ostream cout;          ///< Linked to standard output
      |                  ^~~~
Language: C

#include<stdio.h>
#include<math.h>
#include<stdlib.h>
#include<string.h>
#include<stdbool.h>

#define MOD 998244353

#define MIN(a,b) ((a)<(b)?(a):(b));
#define MAX(a,b) ((a)>(b)?(a):(b));

typedef long long int64;

int main(void){
    int H,W;
    scanf("%d %d",&H,&W);
    int h,w;
    scanf("%d %d",&H,&W);

    printf("%d",(H-h)*(W-w)));
    
    
    return 0;
}

Compiler output:
main.c: In function 'main':
main.c:20:29: error: expected ';' before ')' token
   20 |     printf("%d",(H-h)*(W-w)));
      |                             ^
      |                             ;
main.c:20:29: error: expected statement before ')' token